开发者

How do I close InfoBubble? (google maps utility library v3)

I'm working with google maps utility library. More specifically with infoBubble, and I'm currently able to open an InfoBubble for a Marker, placed on my google map. What I want to know is how to attach an event to close that 开发者_如何学JAVAinfoBubble. I'm struggling with this. Please help me.

Sincerely,

J


        // Listen for user click on map to close any open info bubbles
        google.maps.event.addListener(map, "click", function () { 
          infoBubble.close();
        });


In the infobubble options simply write hideCloseButton: false,. You will be able to see a close button on the right top corner of the infobubble or add an event as DeeZone's answer has shown.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜