Google Maps v3 block map interaction - google-maps

I am trying to make a Polyline editor, just like the one from Google Drawings Library. (for specific reasons, i can't use that one)
It works on the same principle. Start with a point, then for each click add new points and make the polyline.
On the editor from Google Drawings Library, while you are editing a polyline, you're mouse can't interact with other items from the map.
Inspecting with firebug, i see that they have an overlay of 20000000 z-index inside the map.
Is there any way of creating the same overlay for my map using default Google Maps functions?

It's a custom overlay inside the overlayMouseTarget-pane with the same size as the map and a draw-method that updates the position of the overlay. You may do the same.

Related

Google Maps iOS custom UIView instead of a marker

I'm looking for a way to use a custom UIView (not just a custom image) instead of default marker provided by Google Maps iOS SDK. Basically I need a possibility to place my UIView agains proper coordinates of the map, so not necessarily to use markers as they are, just any suitable solution. Any ideas?
There is not currently a way to do this. You can view the relevent feature request (and star it, to show interest) here: https://code.google.com/p/gmaps-api-issues/issues/detail?id=5203
The marker only shows an image. So it cannot take a CustomView. Moreover, if your custom view has some sort of button on it there is no way you can track the events from those button.
In simple words the map renders the markers as UIImage.

Clicking markers on Google Static Maps

I have an application that downloads static images off Google maps, with markers placed where I want them (Placed by passing arguments into the Google Static Maps URL). However, I also need to be able to click the markers. I figured I could convert the x and y coordinate is the click to lon/lat, and then figure out that way which marker was clicked, but I haven't found that too easy.
I know the dimensions of the map in pixels, the zoom level, and the centre point of the map in pixels and lon/lat, so I followed this blog post. Unfortunately this didn't work.
Does anyone know how I could do this, or know another way I could figure out if a marker has been clicked? I'm forced to use the Static maps unfortunately, so I can't do any of it with the JavaScript API
See:
http://home.provide.net/~bratliff/largetiles/
or
http://home.provide.net/~bratliff/harbor/
It is not exactly what you are doing but it does demonstrate Mercator projection conversions & cross-browser mouse events.

Remove/hide default maps layer in google maps and add image overlay

So basically what i'm trying to achieve is this functionality in google maps v3,that they have in openlayers: http://dev.openlayers.org/releases/OpenLayers-2.11/examples/image-layer.html
Hide the base layer of googlemaps (the actual map), and then add a image overlay that is placed over the entire surface of the map.
Is this possible? and do anyone have any solutions at hand?
It's called a GroundOverlay: https://developers.google.com/maps/documentation/javascript/reference#GroundOverlay
However, while a GroundOverlay covers the base map, it does not remove it. You'd need a custom map type for that: https://developers.google.com/maps/documentation/javascript/maptypes#CustomMapTypes
It would be fairly easy to develop a custom map type that always returns a blank tile.

Google map API v3 markers overlapping

I am making an application with google maps.
When markers are overlapping only the last one is displayed even if the icons are different..
I do not want it to cluster in that case, rather it should show both maybe by changing the coordinates just a but??
Any solutions??
I think this is a pretty elegant solution, called Spiderfying the markers.
https://github.com/jawj/OverlappingMarkerSpiderfier
I'm thinking of using it.
What I do now is use JavaScript to make a fancy popup that hides and shows divs on one marker location (created problematically in PHP, but you could do it on JS too). It has the side benefit of allowing less markers on the map.
Click a black numbered marker on this map to see it in action.
http://www.yourmapper.com/map/111/crime-reports/crime-in-metro-louisville-ky-since-jan-2003.htm
Another option is to use Google Maps API 3 Utility Library, it has a Marker Clusterer.

How the blue dot in google maps is centered at the current location?

i have several questions about the blue dot that appears when i launch the google maps in the browser. I tried implementing the same by using the blue dot image as the icon property of the marker and changing the position of the marker in accordance with the current location. So when i do this its actually like the maps are refreshing where as in the google maps application the blue dot is moving smoothly(and that's very awesome). My question
is whether blue dot in google maps is implemented as a marker which changes its
position or is it an inbuilt property of google maps which we can use.
i am using google maps API v3 to do this.
Thanks for any information.
It's a marker with custom icon which is placed with HTML 5 position provided by most recent browsers.
When the position change, you can change marker position.
http://www.kmcgraphics.com/google/