r61290 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r61289‎ | r61290 | r61291 >
Date:02:43, 20 January 2010
Author:jeroendedauw
Status:deferred
Tags:
Comment:
Changes for 0.5.3.
* Google Maps v3 support
Modified paths:
  • /trunk/extensions/SemanticMaps/GoogleMaps/SM_GoogleMaps.php (modified) (history)
  • /trunk/extensions/SemanticMaps/QueryPrinters/SM_QueryPrinters.php (modified) (history)
  • /trunk/extensions/SemanticMaps/SM_Settings.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticMaps/SM_Settings.php
@@ -28,15 +28,13 @@
2929 $egMapsAvailableFeatures['qp'] = array(
3030 'name' => 'Query Printer',
3131 'class' => 'SMQueryPrinters',
32 - 'file' => 'SemanticMaps/QueryPrinters/SM_QueryPrinters.php',
33 - 'local' => false
 32+ 'file' => 'SemanticMaps/QueryPrinters/SM_QueryPrinters.php'
3433 );
3534
3635 $egMapsAvailableFeatures['fi'] = array(
3736 'name' => 'Form input',
3837 'class' => 'SMFormInputs',
39 - 'file' => 'SemanticMaps/FormInputs/SM_FormInputs.php',
40 - 'local' => false
 38+ 'file' => 'SemanticMaps/FormInputs/SM_FormInputs.php'
4139 );
4240
4341
@@ -59,5 +57,5 @@
6058 # Array of String. The default mapping service for each feature, which will be used when no valid service is provided by the user.
6159 # Each service needs to be enabled, if not, the first one from the available services will be taken.
6260 # Note: The default service needs to be available for the feature you set it for, since it's used as a fallback mechanism.
63 -$egMapsDefaultServices['qp'] = 'googlemaps';
64 -$egMapsDefaultServices['fi'] = 'googlemaps';
 61+$egMapsDefaultServices['qp'] = 'googlemaps2';
 62+$egMapsDefaultServices['fi'] = 'googlemaps2';
Index: trunk/extensions/SemanticMaps/QueryPrinters/SM_QueryPrinters.php
@@ -135,7 +135,7 @@
136136
137137 // Load the QP class when it's not loaded yet
138138 if (! array_key_exists($qp['class'], $wgAutoloadClasses)) {
139 - $file = $qp['local'] ? $smgIP . '/' . $qp['file'] : $qp['file'];
 139+ $file = array_key_exists('local', $qp) && $qp['local'] ? $smgIP . '/' . $qp['file'] : $qp['file'];
140140 $wgAutoloadClasses[$qp['class']] = $file;
141141 }
142142
Index: trunk/extensions/SemanticMaps/GoogleMaps/SM_GoogleMaps.php
@@ -20,5 +20,5 @@
2121 die( 'Not an entry point.' );
2222 }
2323
24 -$egMapsServices['googlemaps']['qp'] = array('class' => 'SMGoogleMapsQP', 'file' => 'GoogleMaps/SM_GoogleMapsQP.php', 'local' => true);
25 -$egMapsServices['googlemaps']['fi'] = array('class' => 'SMGoogleMapsFormInput', 'file' => 'GoogleMaps/SM_GoogleMapsFormInput.php', 'local' => true);
\ No newline at end of file
 24+$egMapsServices['googlemaps2']['qp'] = array('class' => 'SMGoogleMapsQP', 'file' => 'GoogleMaps/SM_GoogleMapsQP.php', 'local' => true);
 25+$egMapsServices['googlemaps2']['fi'] = array('class' => 'SMGoogleMapsFormInput', 'file' => 'GoogleMaps/SM_GoogleMapsFormInput.php', 'local' => true);
\ No newline at end of file

Status & tagging log