Zn2O / gwt-google-apis

Automatically exported from code.google.com/p/gwt-google-apis
0 stars 0 forks source link

Have InfoWindow return same object instance for each Map #167

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Found in Release:
r718

Detailed description:
Each time you call map.getInfoWindow() or marker.getInfoWindow() you get a
new instance of the InfoWindow object. In fact, there is only on instance
of the object in JS for each GMap2 object.  

The problem with this, besides being a bit wasteful of cpu & memory
resources, is that the event handling can be very screwy.  For example

map.getInfoWindow.removeXXXHandler() will never do anything.  It constructs
a new InfoWindow object with no handlers.

Workaround if you have one:
Be careful to always keep the InfoWindow object you get from the map -
don't repeatedly call map.getInfoWindow() or marker.getInfoWindow()

Links to the relevant GWT Developer Forum posts:
See issue 156

Original issue reported on code.google.com by galgwt.reviews@gmail.com on 4 Sep 2008 at 3:02

GoogleCodeExporter commented 9 years ago

Original comment by galgwt.reviews@gmail.com on 14 Sep 2008 at 12:02

GoogleCodeExporter commented 9 years ago
Committed as r790.

Original comment by galgwt.reviews@gmail.com on 15 Sep 2008 at 5:50

GoogleCodeExporter commented 9 years ago

Original comment by galgwt.reviews@gmail.com on 13 Oct 2008 at 8:54

GoogleCodeExporter commented 9 years ago

Original comment by galgwt.reviews@gmail.com on 11 Dec 2008 at 3:08

GoogleCodeExporter commented 9 years ago

Original comment by zundel@google.com on 21 Dec 2009 at 1:57