admin管理员组文章数量:1333211
How can I render a custom OverlayView item behind a marker. When a marker and the overlayView item intersects, always overlayview item is drawn on top. Is there a way to adjust their z depth accordingly ?
Thanks
How can I render a custom OverlayView item behind a marker. When a marker and the overlayView item intersects, always overlayview item is drawn on top. Is there a way to adjust their z depth accordingly ?
Thanks
Share Improve this question asked Apr 13, 2012 at 7:02 eenkoexeenkoex 532 silver badges7 bronze badges 03 Answers
Reset to default 8Found the answer here.
In the onAdd
method replace:
panes.overlayImage.appendChild(div);
with:
panes.mapPane.appendChild(div);
The overlayLayer
pane is also rendered below the markers:
var panes = this.getPanes(); panes.overlayLayer.appendChild(div);
You'll probably need to adjust the z-order of the contents of the OverlayView, as outlined here. Make the DOM nodes in the OverlayView have lower z-order values than the marker.
本文标签: google maps api 3Marker on top of OverlayViewGoogleMaps API V3 JavaScriptStack Overflow
版权声明:本文标题:google maps api 3 - Marker on top of OverlayView , GoogleMaps API V3 JavaScript - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1742275757a2445164.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论