I have multiple markers and when you click to open the bubble text it allows for them all to set open even when you click another. Would like for it to close the bubble that is open when you click a new one. Using googlev3, any suggestions? Todd
I added to mxn.googlev3 a bubble.close when i open a bubble. but i check if it''s not null before. Rafael Coutinho Software Engineer Professional profile: www.linkedin.com/in/rafaelcoutinho Beer profile: cervejasquebebi.blogspot.com On Tue, Jan 10, 2012 at 9:08 AM, Todd Loomis <tloomis at clearbox.com> wrote:> I have multiple markers and when you click to open the bubble text it > allows for them all to set open even when you click another. Would like for > it to close the bubble that is open when you click a new one. Using > googlev3, any suggestions? > > Todd > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120110/b2b65c87/attachment.htm>
How would I do that? On Jan 10, 2012, at 6:25 AM, Rafael Coutinho wrote:> I added to mxn.googlev3 a bubble.close when i open a bubble. but i check if it''s not null before. > > Rafael Coutinho > Software Engineer > Professional profile: www.linkedin.com/in/rafaelcoutinho > Beer profile: cervejasquebebi.blogspot.com > > > > On Tue, Jan 10, 2012 at 9:08 AM, Todd Loomis <tloomis at clearbox.com> wrote: > I have multiple markers and when you click to open the bubble text it allows for them all to set open even when you click another. Would like for it to close the bubble that is open when you click a new one. Using googlev3, any suggestions? > > Todd > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120110/bec9a50b/attachment.htm>
I added to the marker click listener this: if (this.infoBubble) { var event_action = "click"; google.maps.event.addListener(marker, event_action, function() { marker.mapstraction_marker.closeBubble(); marker.mapstraction_marker .openBubble(); }); } so we execute close bubble when opening a new one. Rafael Coutinho Software Engineer Professional profile: www.linkedin.com/in/rafaelcoutinho Beer profile: cervejasquebebi.blogspot.com On Tue, Jan 10, 2012 at 10:36 AM, Todd Loomis <tloomis at clearbox.com> wrote:> How would I do that? > > On Jan 10, 2012, at 6:25 AM, Rafael Coutinho wrote: > > I added to mxn.googlev3 a bubble.close when i open a bubble. but i check > if it''s not null before. > > Rafael Coutinho > Software Engineer > Professional profile: www.linkedin.com/in/rafaelcoutinho > Beer profile: cervejasquebebi.blogspot.com > > > > On Tue, Jan 10, 2012 at 9:08 AM, Todd Loomis <tloomis at clearbox.com> wrote: > >> I have multiple markers and when you click to open the bubble text it >> allows for them all to set open even when you click another. Would like for >> it to close the bubble that is open when you click a new one. Using >> googlev3, any suggestions? >> >> Todd >> _______________________________________________ >> Mapstraction mailing list >> Mapstraction at lists.mapstraction.com >> http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com >> > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > > > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120110/09daea93/attachment.htm>
I tired to add this and nothing happens. On Jan 10, 2012, at 7:57 AM, Rafael Coutinho wrote:> I added to the marker click listener this: > > if (this.infoBubble) { > var event_action = "click"; > google.maps.event.addListener(marker, > event_action, function() { > marker.mapstraction_marker.closeBubble(); > marker.mapstraction_marker > .openBubble(); > }); > } > > so we execute close bubble when opening a new one. > > Rafael Coutinho > Software Engineer > Professional profile: www.linkedin.com/in/rafaelcoutinho > Beer profile: cervejasquebebi.blogspot.com > > > > On Tue, Jan 10, 2012 at 10:36 AM, Todd Loomis <tloomis at clearbox.com> wrote: > How would I do that? > > On Jan 10, 2012, at 6:25 AM, Rafael Coutinho wrote: > >> I added to mxn.googlev3 a bubble.close when i open a bubble. but i check if it''s not null before. >> >> Rafael Coutinho >> Software Engineer >> Professional profile: www.linkedin.com/in/rafaelcoutinho >> Beer profile: cervejasquebebi.blogspot.com >> >> >> >> On Tue, Jan 10, 2012 at 9:08 AM, Todd Loomis <tloomis at clearbox.com> wrote: >> I have multiple markers and when you click to open the bubble text it allows for them all to set open even when you click another. Would like for it to close the bubble that is open when you click a new one. Using googlev3, any suggestions? >> >> Todd >> _______________________________________________ >> Mapstraction mailing list >> Mapstraction at lists.mapstraction.com >> http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com >> >> _______________________________________________ >> Mapstraction mailing list >> Mapstraction at lists.mapstraction.com >> http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120110/6578ad07/attachment.htm>
I still am having trouble getting this to work, added and nothing changes? On Jan 10, 2012, at 7:57 AM, Rafael Coutinho wrote:> I added to the marker click listener this: > > if (this.infoBubble) { > var event_action = "click"; > google.maps.event.addListener(marker, > event_action, function() { > marker.mapstraction_marker.closeBubble(); > marker.mapstraction_marker > .openBubble(); > }); > } > > so we execute close bubble when opening a new one. > > Rafael Coutinho > Software Engineer > Professional profile: www.linkedin.com/in/rafaelcoutinho > Beer profile: cervejasquebebi.blogspot.com > > > > On Tue, Jan 10, 2012 at 10:36 AM, Todd Loomis <tloomis at clearbox.com> wrote: > How would I do that? > > On Jan 10, 2012, at 6:25 AM, Rafael Coutinho wrote: > >> I added to mxn.googlev3 a bubble.close when i open a bubble. but i check if it''s not null before. >> >> Rafael Coutinho >> Software Engineer >> Professional profile: www.linkedin.com/in/rafaelcoutinho >> Beer profile: cervejasquebebi.blogspot.com >> >> >> >> On Tue, Jan 10, 2012 at 9:08 AM, Todd Loomis <tloomis at clearbox.com> wrote: >> I have multiple markers and when you click to open the bubble text it allows for them all to set open even when you click another. Would like for it to close the bubble that is open when you click a new one. Using googlev3, any suggestions? >> >> Todd >> _______________________________________________ >> Mapstraction mailing list >> Mapstraction at lists.mapstraction.com >> http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com >> >> _______________________________________________ >> Mapstraction mailing list >> Mapstraction at lists.mapstraction.com >> http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120113/0bdcd378/attachment.htm>
Hi, You can also do it in a "tricky" way like this : for (i in map.markers) { map.markers[i].closeBubble(); } This will close the bubble of all map''s markers. ++ b_b Le 13/01/2012 11:17, Todd Loomis a ?crit :> I still am having trouble getting this to work, added and nothing changes? >
I put this as a on document ready and doesn''t seem to work On Jan 13, 2012, at 5:32 AM, Bruno Bergot wrote:> Hi, > > You can also do it in a "tricky" way like this : > > for (i in map.markers) { > map.markers[i].closeBubble(); > } > > This will close the bubble of all map''s markers. > > ++ > b_b > > > Le 13/01/2012 11:17, Todd Loomis a ?crit : >> I still am having trouble getting this to work, added and nothing changes? >> >
I added this: marker.click.addHandler(function(event_name, event_source, event_args) { for (i in mapstraction.markers) { mapstraction_markers[1].closeBubble(); } }); But tells me closeBubble(); is not a function? On Jan 13, 2012, at 9:09 AM, Todd Loomis wrote:> I put this as a on document ready and doesn''t seem to work > > On Jan 13, 2012, at 5:32 AM, Bruno Bergot wrote: > >> Hi, >> >> You can also do it in a "tricky" way like this : >> >> for (i in map.markers) { >> map.markers[i].closeBubble(); >> } >> >> This will close the bubble of all map''s markers. >> >> ++ >> b_b >> >> >> Le 13/01/2012 11:17, Todd Loomis a ?crit : >>> I still am having trouble getting this to work, added and nothing changes? >>> >> > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120117/c15aadb9/attachment.htm>
It''s trickier than it probably should be. Here''s a modification of one of the examples that works: https://gist.github.com/1630668. Save it in the examples directory of mxn tree or modify the path to mxn.js. -dylan- On Tue, Jan 17, 2012 at 5:47 PM, Todd Loomis <tloomis at clearbox.com> wrote:> I added this: > > marker.click.addHandler(function(event_name, event_source, event_args) { > > > for (i in mapstraction.markers) { > mapstraction_markers[1].closeBubble(); > } > > > > }); > > But tells me closeBubble(); is not a function? > * * > > On Jan 13, 2012, at 9:09 AM, Todd Loomis wrote: > > I put this as a on document ready and doesn''t seem to work > > On Jan 13, 2012, at 5:32 AM, Bruno Bergot wrote: > > Hi, > > > You can also do it in a "tricky" way like this : > > > for (i in map.markers) { > > map.markers[i].closeBubble(); > > } > > > This will close the bubble of all map''s markers. > > > ++ > > b_b > > > > Le 13/01/2012 11:17, Todd Loomis a ?crit : > > I still am having trouble getting this to work, added and nothing changes? > > > > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > > > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120117/359bbbd4/attachment.htm>
This doesn''t work. I am look to have any open bubbles close when a marker is clicked to open a bubble. On Jan 17, 2012, at 10:29 PM, Dylan Kuhn wrote:> It''s trickier than it probably should be. Here''s a modification of one of the examples that works: https://gist.github.com/1630668. Save it in the examples directory of mxn tree or modify the path to mxn.js. > > -dylan- > > On Tue, Jan 17, 2012 at 5:47 PM, Todd Loomis <tloomis at clearbox.com> wrote: > I added this: > > marker.click.addHandler(function(event_name, event_source, event_args) { > > > for (i in mapstraction.markers) { > mapstraction_markers[1].closeBubble(); > } > > > > }); > > But tells me closeBubble(); is not a function? > > On Jan 13, 2012, at 9:09 AM, Todd Loomis wrote: > >> I put this as a on document ready and doesn''t seem to work >> >> On Jan 13, 2012, at 5:32 AM, Bruno Bergot wrote: >> >>> Hi, >>> >>> You can also do it in a "tricky" way like this : >>> >>> for (i in map.markers) { >>> map.markers[i].closeBubble(); >>> } >>> >>> This will close the bubble of all map''s markers. >>> >>> ++ >>> b_b >>> >>> >>> Le 13/01/2012 11:17, Todd Loomis a ?crit : >>>> I still am having trouble getting this to work, added and nothing changes? >>>> >>> >> >> _______________________________________________ >> Mapstraction mailing list >> Mapstraction at lists.mapstraction.com >> http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120118/8b607bf0/attachment-0001.htm>
tired changing to this .closeInfoBubble.fire(); still not closing On Jan 18, 2012, at 8:53 AM, Todd Loomis wrote:> This doesn''t work. I am look to have any open bubbles close when a marker is clicked to open a bubble. > > On Jan 17, 2012, at 10:29 PM, Dylan Kuhn wrote: > >> It''s trickier than it probably should be. Here''s a modification of one of the examples that works: https://gist.github.com/1630668. Save it in the examples directory of mxn tree or modify the path to mxn.js. >> >> -dylan- >> >> On Tue, Jan 17, 2012 at 5:47 PM, Todd Loomis <tloomis at clearbox.com> wrote: >> I added this: >> >> marker.click.addHandler(function(event_name, event_source, event_args) { >> >> >> for (i in mapstraction.markers) { >> mapstraction_markers[1].closeBubble(); >> } >> >> >> >> }); >> >> But tells me closeBubble(); is not a function? >> >> On Jan 13, 2012, at 9:09 AM, Todd Loomis wrote: >> >>> I put this as a on document ready and doesn''t seem to work >>> >>> On Jan 13, 2012, at 5:32 AM, Bruno Bergot wrote: >>> >>>> Hi, >>>> >>>> You can also do it in a "tricky" way like this : >>>> >>>> for (i in map.markers) { >>>> map.markers[i].closeBubble(); >>>> } >>>> >>>> This will close the bubble of all map''s markers. >>>> >>>> ++ >>>> b_b >>>> >>>> >>>> Le 13/01/2012 11:17, Todd Loomis a ?crit : >>>>> I still am having trouble getting this to work, added and nothing changes? >>>>> >>>> >>> >>> _______________________________________________ >>> Mapstraction mailing list >>> Mapstraction at lists.mapstraction.com >>> http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com >> >> >> _______________________________________________ >> Mapstraction mailing list >> Mapstraction at lists.mapstraction.com >> http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com >> >> >> _______________________________________________ >> Mapstraction mailing list >> Mapstraction at lists.mapstraction.com >> http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120118/17524a69/attachment.htm>
Is this default behaviour in V3? Sounds like the provider default settings in the unit need amending to me. Derek On Jan 18, 2012 2:30 PM, "Todd Loomis" <tloomis at clearbox.com> wrote:> tired changing to this > > .closeInfoBubble.fire(); > > still not closing > > On Jan 18, 2012, at 8:53 AM, Todd Loomis wrote: > > This doesn''t work. I am look to have any open bubbles close when a marker > is clicked to open a bubble. > > On Jan 17, 2012, at 10:29 PM, Dylan Kuhn wrote: > > It''s trickier than it probably should be. Here''s a modification of one of > the examples that works: https://gist.github.com/1630668. Save it in the > examples directory of mxn tree or modify the path to mxn.js. > > -dylan- > > On Tue, Jan 17, 2012 at 5:47 PM, Todd Loomis <tloomis at clearbox.com> wrote: > >> I added this: >> >> marker.click.addHandler(function(event_name, event_source, event_args) { >> >> >> for (i in mapstraction.markers) { >> mapstraction_markers[1].closeBubble(); >> } >> >> >> >> }); >> >> But tells me closeBubble(); is not a function? >> * * >> >> On Jan 13, 2012, at 9:09 AM, Todd Loomis wrote: >> >> I put this as a on document ready and doesn''t seem to work >> >> On Jan 13, 2012, at 5:32 AM, Bruno Bergot wrote: >> >> Hi, >> >> >> You can also do it in a "tricky" way like this : >> >> >> for (i in map.markers) { >> >> map.markers[i].closeBubble(); >> >> } >> >> >> This will close the bubble of all map''s markers. >> >> >> ++ >> >> b_b >> >> >> >> Le 13/01/2012 11:17, Todd Loomis a ?crit : >> >> I still am having trouble getting this to work, added and nothing changes? >> >> >> >> >> _______________________________________________ >> Mapstraction mailing list >> Mapstraction at lists.mapstraction.com >> http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com >> >> >> >> _______________________________________________ >> Mapstraction mailing list >> Mapstraction at lists.mapstraction.com >> http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com >> >> > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > > > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120123/228c7f5f/attachment-0001.htm>
> > Is this default behaviour in V3? Sounds like the provider default settings > in the unit need amending to me. > > > You mean allowing more than one info window open at a time? That''s defaultbehavior for openlayers too - not sure about others. Should we standardize on one-bubble-at-a-time as default? Provide a way to allow multiples if possible? dylan- -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120123/f56369d1/attachment.htm>
Sorry, I meant "init" not unit in the last message, stupid autocorrect. Yes, I think default behaviour should be standardised and as for allowing multiple bubbles we should check whether all providers support it and if so add an option in for enabling it. Derek On Jan 23, 2012 4:00 PM, "Dylan Kuhn" <dylan.k.kuhn at gmail.com> wrote:> Is this default behaviour in V3? Sounds like the provider default settings >> in the unit need amending to me. >> >> >> You mean allowing more than one info window open at a time? That''s > default behavior for openlayers too - not sure about others. Should we > standardize on one-bubble-at-a-time as default? Provide a way to allow > multiples if possible? > > dylan- > > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com > >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120123/e385ed5b/attachment.htm>
Looks like googleV3 allows multiple bubbles to open, however no option to close them. I have tired several suggestions and can get the listener but the buttonClose never fires. On Jan 23, 2012, at 11:00 AM, Dylan Kuhn wrote:> Is this default behaviour in V3? Sounds like the provider default settings in the unit need amending to me. > > > > You mean allowing more than one info window open at a time? That''s default behavior for openlayers too - not sure about others. Should we standardize on one-bubble-at-a-time as default? Provide a way to allow multiples if possible? > > dylan- > _______________________________________________ > Mapstraction mailing list > Mapstraction at lists.mapstraction.com > http://lists.mapstraction.com/listinfo.cgi/mapstraction-mapstraction.com-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120123/809d86b5/attachment.htm>
> > Yes, I think default behaviour should be standardised and as for allowing > multiple bubbles we should check whether all providers support it and if so > add an option in for enabling it. > > As far as I know Google v2 still has only one info window per map, so itmay be the control case: http://code.google.com/apis/maps/documentation/javascript/v2/reference.html#GMap2.getInfoWindow -dylan- -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mapstraction.com/pipermail/mapstraction-mapstraction.com/attachments/20120123/9e6c9736/attachment.htm>