Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Using Chrome 44 on Mac OS.
To reproduce:
- click "Add an area"
- zoom in to max zoom
- select geometry type of polygon
- draw a polygon on the map
- zoom out
- observe the polygon not where you originally drew it
Comments
Comment #2
m.stentaAh good catch. Sounds like a map projection issue... :-/
Thanks for the bug report!
Moving this to Farm Area module...
Comment #3
m.stentaHm, actually... might have more to do with the available zoom levels of Google Maps. I took a look at your rj.farmos.net site - and I think I see what you mean. I'll run some tests and see if I can nail it down...
Comment #4
m.stentaYikes, it gets even weirder if you pan the map around after creating a shape like this. It's all of a sudden disconnected from the map, and pans at a multiplied rate!
Comment #5
m.stentaIt only seems to happen in certain places too... not everywhere.
Comment #6
m.stentaI figured out why this was happening: the Google Maps API does not allow you to zoom past a certain level. This makes sense, they only have imagery for certain zoom levels. Unfortunately, if you ask the API for tiles at a higher zoom level, it doesn't return empty tiles as you might expect - instead it returns the same map tiles as before (at the max zoom level). So the Google Maps tiles make it LOOK like you're only zoomed into 20, but everything else in Openlayers is actually zoomed to 24 (for example).
I put a rough fix into place a while back and forgot to update this issue. My rough fix was to simply not allow the map to be zoomed more than 20 (it seems like that is the max for most of Google Maps).
Now, I want to be able to zoom farther than that, so I created a new feature request: #2680273: Allow zooming past Google Map limit
Closing this as "fixed".
Comment #7
m.stentaMoving old issues to the canonical farmOS project for easier searching. Apologies for email spam if anyone is following these. :-)