How to check if the markers in a google map are not behind any custom controls in the Map - google-maps

I'm using Google maps V3 API . I've added a custom control on the Map. Its having a width of 350px and height 300px.
Is there any way which i can figure out any of the marker is positioned behind the custom control on the Google maps.
Also i need to find out if i could able to find any marker is behind the custom control , i want it to change the position of the marker out of the custom control.

Related

Google Maps v3 block map interaction

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.

GWT map error display grey area

I have created a widget to display google earth and when I click the button, google earth disappears and is replaced by google map.
I am using the gwt earth 3 and gwt map v3. When I click the button the first time, google map is display well.
But when I click the button again, google map is displayed very small inside a grey area like that, which used gwt-map v2.
In gwt map v3, it doesn't have method checkResizeAndCenter(). So I want know if there is another way to fix this error.
Anybody can help me?
I think you had situation like,map widget get added to a panel having width and height greater than width and height of map widget.

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 Maps - Infobox API - scroll pane vs change position

Using Google Maps InfoBox -
http://google-maps-utility-library-v3.googlecode.com/svn/trunk/infobox/docs/reference.html
Currently the map will scroll - pan control - when your infobox is outside of the bounds of the map.
I'm looking for a way to detect if the infobox will be outside of the bounds of the map, and if so the position is switched (currently I have the infoBoxAnchor set at 9,2) - so set the infoboxanchor in the opposite x direction.
Anyone done anything like this?
Thanks.
Could be tricky - infowindows are dynamically sized based on the content in them. What you could do, is in the InfoWindowOptions, set disableAutoPan=true. This will prevent the map panning to display the infowindow. Then I'm guessing you could use jQuery (or any other JS you like) to figure out:
the size of the infowindow based on the position where it's anchored to on the map,
is the entire infowindow visible
if not, move the infowindow's position
Related:
Auto adjustment of InfoWindow position on Google Maps
Google Maps Mashup with Intelligently positioning InfoBox
Google Maps: How to prevent InfoWindow from shifting the map
And a possible solution (thanks to above links) at http://gmaps-samples-v3.googlecode.com/svn/trunk/smartinfowindow/smartinfowindow.html

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/