r79318 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r79317‎ | r79318 | r79319 >
Date:03:22, 31 December 2010
Author:jeroendedauw
Status:deferred
Tags:
Comment:
Changes for 0.7.4 - added descriptions to the parser hooks
Modified paths:
  • /trunk/extensions/Maps/Maps.i18n.php (modified) (history)
  • /trunk/extensions/Maps/includes/parserHooks/Maps_Coordinates.php (modified) (history)
  • /trunk/extensions/Maps/includes/parserHooks/Maps_DisplayMap.php (modified) (history)
  • /trunk/extensions/Maps/includes/parserHooks/Maps_DisplayPoint.php (modified) (history)
  • /trunk/extensions/Maps/includes/parserHooks/Maps_Distance.php (modified) (history)
  • /trunk/extensions/Maps/includes/parserHooks/Maps_Finddestination.php (modified) (history)
  • /trunk/extensions/Maps/includes/parserHooks/Maps_Geocode.php (modified) (history)
  • /trunk/extensions/Maps/includes/parserHooks/Maps_Geodistance.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Maps/Maps.i18n.php
@@ -36,6 +36,15 @@
3737 'maps-layer-of-type' => 'Layer of type $1',
3838 'maps-layer-type-supported-by' => 'This layer type can {{PLURAL:$2|only be used with the $1 mapping service|be used with these mapping services: $1}}.',
3939
 40+ // Parser function descriptions
 41+ 'maps-coordinates-description' => 'Parser hook to format coordinates, from and to any of the supported formats.',
 42+ 'maps-displaymap-description' => 'Display geographical maps without any wiki-defined markers on them.',
 43+ 'maps-displaypoint-description' => 'Display geographical maps with one or more wiki-defined markers on them.',
 44+ 'maps-distance-description' => "Convert a distance using a certain supported unit to it's equivalent using another unit.",
 45+ 'maps-finddestination-description' => 'Find a destination given a starting point(that can be in any of the supported formats), an initial bearing and a distance.',
 46+ 'maps-geocode-description' => 'Enables the geocoding of addresses, in other words, turning human readable locations into sets of coordinates. There is support for several geocoding services, which should not be confused with mapping services.',
 47+ 'maps-geodistance-description' => 'Calculate the geographical distance between two points, from and to any of the supported formats.',
 48+
4049 // Validation
4150 'validation-error-invalid-location' => 'Parameter $1 must be a valid location.',
4251 'validation-error-invalid-locations' => 'Parameter $1 must be one or more valid locations.',
Index: trunk/extensions/Maps/includes/parserHooks/Maps_Coordinates.php
@@ -125,4 +125,13 @@
126126 return $output;
127127 }
128128
 129+ /**
 130+ * @see ParserHook::getDescription()
 131+ *
 132+ * @since 0.7.4
 133+ */
 134+ public function getDescription() {
 135+ return wfMsg( 'maps-coordinates-description' );
 136+ }
 137+
129138 }
\ No newline at end of file
Index: trunk/extensions/Maps/includes/parserHooks/Maps_Distance.php
@@ -106,5 +106,14 @@
107107 $distanceInMeters = MapsDistanceParser::parseDistance( $parameters['distance'] );
108108 return MapsDistanceParser::formatDistance( $distanceInMeters, $parameters['unit'], $parameters['decimals'] );
109109 }
 110+
 111+ /**
 112+ * @see ParserHook::getDescription()
 113+ *
 114+ * @since 0.7.4
 115+ */
 116+ public function getDescription() {
 117+ return wfMsg( 'maps-distance-description' );
 118+ }
110119
111120 }
\ No newline at end of file
Index: trunk/extensions/Maps/includes/parserHooks/Maps_DisplayPoint.php
@@ -151,5 +151,14 @@
152152 'isHTML' => true
153153 );
154154 }
155 -
 155+
 156+ /**
 157+ * @see ParserHook::getDescription()
 158+ *
 159+ * @since 0.7.4
 160+ */
 161+ public function getDescription() {
 162+ return wfMsg( 'maps-displaypoint-description' );
 163+ }
 164+
156165 }
\ No newline at end of file
Index: trunk/extensions/Maps/includes/parserHooks/Maps_Finddestination.php
@@ -170,5 +170,14 @@
171171
172172 return $output;
173173 }
 174+
 175+ /**
 176+ * @see ParserHook::getDescription()
 177+ *
 178+ * @since 0.7.4
 179+ */
 180+ public function getDescription() {
 181+ return wfMsg( 'maps-finddestination-description' );
 182+ }
174183
175184 }
\ No newline at end of file
Index: trunk/extensions/Maps/includes/parserHooks/Maps_DisplayMap.php
@@ -119,5 +119,14 @@
120120 'isHTML' => true
121121 );
122122 }
123 -
 123+
 124+ /**
 125+ * @see ParserHook::getDescription()
 126+ *
 127+ * @since 0.7.4
 128+ */
 129+ public function getDescription() {
 130+ return wfMsg( 'maps-displaymap-description' );
 131+ }
 132+
124133 }
\ No newline at end of file
Index: trunk/extensions/Maps/includes/parserHooks/Maps_Geocode.php
@@ -153,5 +153,14 @@
154154
155155 return $output;
156156 }
 157+
 158+ /**
 159+ * @see ParserHook::getDescription()
 160+ *
 161+ * @since 0.7.4
 162+ */
 163+ public function getDescription() {
 164+ return wfMsg( 'maps-geocode-description' );
 165+ }
157166
158167 }
\ No newline at end of file
Index: trunk/extensions/Maps/includes/parserHooks/Maps_Geodistance.php
@@ -162,5 +162,14 @@
163163
164164 return $output;
165165 }
 166+
 167+ /**
 168+ * @see ParserHook::getDescription()
 169+ *
 170+ * @since 0.7.4
 171+ */
 172+ public function getDescription() {
 173+ return wfMsg( 'maps-geodistance-description' );
 174+ }
166175
167176 }
\ No newline at end of file

Status & tagging log