From f2fe6dd2b5da9a37e67210e3edb854de41c76c4a Mon Sep 17 00:00:00 2001 From: rWatcher Date: Thu, 1 Apr 2010 20:59:36 -0400 Subject: [PATCH] Added some comments. --- modules/exif_gps/views/exif_gps_dynamic2_sidebar.html.php | 4 ++++ modules/exif_gps/views/exif_gps_map.html.php | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/modules/exif_gps/views/exif_gps_dynamic2_sidebar.html.php b/modules/exif_gps/views/exif_gps_dynamic2_sidebar.html.php index 6ae738c2..24b69acb 100644 --- a/modules/exif_gps/views/exif_gps_dynamic2_sidebar.html.php +++ b/modules/exif_gps/views/exif_gps_dynamic2_sidebar.html.php @@ -36,6 +36,10 @@ + // If there is a maximum auto-zoom value, then set up an event to check the zoom + // level the first time it is changed, and adjust it if necessary. + // (if we call map.getZoom right after .fitBounds, getZoom will return the initial + // zoom level, not the auto zoom level, this way we get the auto zoomed value). google.maps.event.addListener(map, 'zoom_changed', function() { if (google_zoom_hack) { if (map.getZoom() > 18) map.setZoom(18); diff --git a/modules/exif_gps/views/exif_gps_map.html.php b/modules/exif_gps/views/exif_gps_map.html.php index 95d8319b..6c8a59ee 100644 --- a/modules/exif_gps/views/exif_gps_map.html.php +++ b/modules/exif_gps/views/exif_gps_map.html.php @@ -63,6 +63,10 @@ }); + // If there is a maximum auto-zoom value, then set up an event to check the zoom + // level the first time it is changed, and adjust it if necessary. + // (if we call map.getZoom right after .fitBounds, getZoom will return the initial + // zoom level, not the auto zoom level, this way we get the auto zoomed value). google.maps.event.addListener(map, 'zoom_changed', function() { if (google_zoom_hack) { if (map.getZoom() > 18) map.setZoom(18);