Index: trunk/extensions/Maps/Maps_Settings.php |
— | — | @@ -428,7 +428,7 @@ |
429 | 429 | 'yahoo' => "<style type='text/css'> #controls {width: 512px;}</style><script src='http://api.maps.yahoo.com/ajaxymap?v=3.0&appid=euzuro-openlayers'></script>", |
430 | 430 | 'bing' => "<script type='$wgJsMimeType' src='http://dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=6.1'></script>", |
431 | 431 | 'ol-wms' => "<script type='$wgJsMimeType' src='http://clients.multimap.com/API/maps/1.1/metacarta_04'></script>", |
432 | | - 'osm' => "<script type='$wgJsMimeType' src='$egMapsScriptPath/Services/OpenLayers/OSM/OpenStreetMap.js?$egMapsStyleVersion'></script>", |
| 432 | + 'osm' => "<script type='$wgJsMimeType' src='$egMapsScriptPath/includes/services/OpenLayers/OSM/OpenStreetMap.js?$egMapsStyleVersion'></script>", |
433 | 433 | ); |
434 | 434 | |
435 | 435 | |
Index: trunk/extensions/Maps/includes/services/OpenLayers/Maps_ParamOLLayers.php |
— | — | @@ -32,7 +32,7 @@ |
33 | 33 | global $egMapsOLLayerGroups; |
34 | 34 | |
35 | 35 | $unpacked = array(); |
36 | | - |
| 36 | + |
37 | 37 | foreach ( $parameter->value as $layerOrGroup ) { |
38 | 38 | if ( array_key_exists( $layerOrGroup, $egMapsOLLayerGroups ) ) { |
39 | 39 | $unpacked = array_merge( $unpacked, $egMapsOLLayerGroups[$layerOrGroup] ); |
Index: trunk/extensions/Maps/includes/services/OpenLayers/Maps_OpenLayersDispMap.php |
— | — | @@ -1,18 +1,13 @@ |
2 | 2 | <?php |
3 | 3 | |
4 | 4 | /** |
5 | | - * Class for handling the display_map parser function with OpenLayers |
| 5 | + * Class for handling the display_map parser function with OpenLayers. |
6 | 6 | * |
7 | 7 | * @file Maps_OpenLayersDispMap.php |
8 | 8 | * @ingroup MapsOpenLayers |
9 | 9 | * |
10 | 10 | * @author Jeroen De Dauw |
11 | 11 | */ |
12 | | - |
13 | | -if ( !defined( 'MEDIAWIKI' ) ) { |
14 | | - die( 'Not an entry point.' ); |
15 | | -} |
16 | | - |
17 | 12 | class MapsOpenLayersDispMap extends MapsBaseMap { |
18 | 13 | |
19 | 14 | /** |
— | — | @@ -20,7 +15,7 @@ |
21 | 16 | */ |
22 | 17 | public function addSpecificMapHTML( Parser $parser ) { |
23 | 18 | global $wgLang; |
24 | | - |
| 19 | + |
25 | 20 | $layerItems = $this->service->createLayersStringAndLoadDependencies( $this->layers ); |
26 | 21 | |
27 | 22 | $mapName = $this->service->getMapId(); |
Index: trunk/extensions/Maps/includes/services/OpenLayers/Maps_OpenLayers.php |
— | — | @@ -65,14 +65,10 @@ |
66 | 66 | $egMapsOLLayers, |
67 | 67 | array(), |
68 | 68 | array( |
69 | | - new CriterionInArray( self::getLayerNames( true ), new ParamManipulationImplode( ',', "'" ) ), |
| 69 | + new CriterionInArray( self::getLayerNames( true ) ), |
70 | 70 | ) |
71 | | - ); |
72 | | - |
73 | | - // TODO |
74 | | - $params['layers']->outputTypes = array( |
75 | | - 'olgroups' => array( 'olgroups' ), |
76 | | - ); |
| 71 | + ); |
| 72 | + $params['layers']->addManipulations( new MapsParamOLLayers() ); |
77 | 73 | } |
78 | 74 | |
79 | 75 | /** |
— | — | @@ -186,7 +182,7 @@ |
187 | 183 | $this->loadDependencyWhenNeeded( $layer ); |
188 | 184 | $layerStr[] = is_array( $egMapsOLAvailableLayers[$layer] ) ? $egMapsOLAvailableLayers[$layer][0] : $egMapsOLAvailableLayers[$layer]; |
189 | 185 | } |
190 | | - |
| 186 | + |
191 | 187 | return count( $layerStr ) == 0 ? '' : 'new ' . implode( ',new ', $layerStr ); |
192 | 188 | } |
193 | 189 | |
Index: trunk/extensions/Maps/includes/parserHooks/Maps_DisplayMap.php |
— | — | @@ -101,7 +101,7 @@ |
102 | 102 | |
103 | 103 | // Get an instance of the class handling the current parser hook and service. |
104 | 104 | $mapClass = $service->getFeatureInstance( $this->getName() ); |
105 | | - |
| 105 | + |
106 | 106 | return $mapClass->getMapHtml( $parameters, $this->parser ); |
107 | 107 | } |
108 | 108 | |