Index: trunk/extensions/Maps/Maps.i18n.php |
— | — | @@ -190,6 +190,7 @@ |
191 | 191 | 'maps-googlemaps3-par-gkml' => 'KML files hosted by Google to load onto the map.', |
192 | 192 | 'maps-googlemaps3-par-fusiontables' => 'IDs of Google Fusion Tables which should be loaded onto the map.', |
193 | 193 | 'maps-googlemaps3-par-tilt' => 'Tilt for the Map when using Google Maps.', |
| 194 | + 'maps-googlemaps3-par-kmlrezoom' => 'Rezoom the map after the KML layers have been loaded.', |
194 | 195 | |
195 | 196 | // OpenLayers |
196 | 197 | 'maps-openlayers-par-controls' => 'The controls to place on the map.', |
Index: trunk/extensions/Maps/Maps_Settings.php |
— | — | @@ -162,6 +162,8 @@ |
163 | 163 | $egMapsDefaultLabel = ''; |
164 | 164 | |
165 | 165 | $egMapsResizableByDefault = false; |
| 166 | + |
| 167 | + $egMapsRezoomForKML = false; |
166 | 168 | |
167 | 169 | |
168 | 170 | |
Index: trunk/extensions/Maps/RELEASE-NOTES |
— | — | @@ -12,6 +12,7 @@ |
13 | 13 | |
14 | 14 | * Added API module for geocoding. |
15 | 15 | * Added 'geocoding' right. |
| 16 | +* Added kmlrezoom parameter for Google Maps v3 and general $egMapsRezoomForKML setting. |
16 | 17 | * Fixed Google Maps v3 JavaScript issue occuring on MediaWiki 1.17. |
17 | 18 | |
18 | 19 | === Maps 1.0.2 === |
Index: trunk/extensions/Maps/includes/services/GoogleMaps3/jquery.googlemap.js |
— | — | @@ -118,7 +118,7 @@ |
119 | 119 | // If there are any non-Google KML/KMZ layers, load the geoxml library and use it to add these layers. |
120 | 120 | if ( options.kml.length != 0 ) { |
121 | 121 | mw.loader.using( 'ext.maps.gm3.geoxml', function() { |
122 | | - var geoXml = new geoXML3.parser( { map: map } ); |
| 122 | + var geoXml = new geoXML3.parser( { map: map, zoom: options.kmlrezoom } ); |
123 | 123 | |
124 | 124 | for ( i = options.kml.length - 1; i >= 0; i-- ) { |
125 | 125 | geoXml.parse( options.kml[i] ); |
Index: trunk/extensions/Maps/includes/services/GoogleMaps3/Maps_GoogleMaps3.php |
— | — | @@ -148,6 +148,10 @@ |
149 | 149 | $params['tilt'] = new Parameter( 'tilt', Parameter::TYPE_INTEGER ); |
150 | 150 | $params['tilt']->setDefault( $egMapsGMaps3DefaultTilt, false ); |
151 | 151 | $params['tilt']->setMessage( 'maps-googlemaps3-par-tilt' ); |
| 152 | + |
| 153 | + $params['kmlrezoom'] = new Parameter( 'kmlrezoom', Parameter::TYPE_BOOLEAN ); |
| 154 | + $params['kmlrezoom']->setDefault( $GLOBALS['egMapsRezoomForKML'], false ); |
| 155 | + $params['kmlrezoom']->setMessage( 'maps-googlemaps3-par-kmlrezoom' ); |
152 | 156 | } |
153 | 157 | |
154 | 158 | /** |