kjenney / gmaps-utility-library-dev

Automatically exported from code.google.com/p/gmaps-utility-library-dev
0 stars 0 forks source link

tall windows repositioned incorrectly #171

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Create an infowindow tall enough so that from bottom of marker to top of
infowindow, it almost takes up map.
2. Reposition it four times, waiting a few seconds between each time.

What is the expected output? What do you see instead?

It should be repositioned to one location, but it alternates between a high
and low position in the map viewport.  When it goes to the high position,
the top of the window is obscured.

Please use labels and text to provide additional information.

The reason this happens in my application is because I have content in the
same infowindow that changes so that it needs to be repositioned each time.

The problem is, the south pan/move to high position does not respect the
top padding.  The move to low position does not respect the bottom padding.
 So the window keeps going back and forth.

To make the pan south/move window up respect the top padding, in
repositionMap_, change this:
 panY = -(offsetBottom - mapSW.y);
to this:
 panY = Math.max( -(offsetBottom - mapSW.y), mapNE.y - offsetTop);

Then the window will be moved up no further than the top padding allows.

Original issue reported on code.google.com by jgarfi...@earthlink.net on 11 Dec 2009 at 1:16

GoogleCodeExporter commented 9 years ago
for extinfowindow, since i didn't mention that before.

Original comment by jgarfi...@earthlink.net on 12 Dec 2009 at 1:11

GoogleCodeExporter commented 9 years ago

Original comment by pamela.fox on 13 Dec 2009 at 6:35

GoogleCodeExporter commented 9 years ago

Original comment by jgarfi...@earthlink.net on 3 Feb 2010 at 1:59

GoogleCodeExporter commented 9 years ago

Original comment by douglass...@earthlink.net on 18 May 2010 at 10:18