r85494 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r85493‎ | r85494 | r85495 >
Date:00:38, 6 April 2011
Author:jeroendedauw
Status:deferred
Tags:
Comment:
added messages for Google Maps v3 params
Modified paths:
  • /trunk/extensions/Maps/Maps.i18n.php (modified) (history)
  • /trunk/extensions/Maps/includes/services/GoogleMaps3/Maps_GoogleMaps3.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Maps/Maps.i18n.php
@@ -159,6 +159,16 @@
160160
161161 // Google Maps v3
162162 'maps-googlemaps3-incompatbrowser' => 'Your browser is not compatible with Google Maps v3.',
 163+ 'maps-googlemaps3-par-type' => 'The map type to initially show.',
 164+ 'maps-googlemaps3-par-types' => 'The map types that will be available via the type control.',
 165+ 'maps-googlemaps3-par-layers' => 'Special layers to load onto the map.',
 166+ 'maps-googlemaps3-par-controls' => 'The controls to place on the map.',
 167+ 'maps-googlemaps3-par-zoomstyle' => 'The style of the zoom control.',
 168+ 'maps-googlemaps3-par-typestyle' => 'The style of the type control.',
 169+ 'maps-googlemaps3-par-autoinfowindows' => 'Automatically open all info windows after the page has loaded.',
 170+ 'maps-googlemaps3-par-kml' => 'KML files to load onto the map.',
 171+ 'maps-googlemaps3-par-fusiontables' => 'IDs of Google Fusion Tables which should be loaded onto the map.',
 172+ 'maps-googlemaps3-par-resizable' => 'Makes the map resizable by dragging at it\'s lower right corner.',
163173 );
164174
165175 /** Message documentation (Message documentation)
Index: trunk/extensions/Maps/includes/services/GoogleMaps3/Maps_GoogleMaps3.php
@@ -91,43 +91,53 @@
9292 $params['type']->setDefault( $egMapsGMaps3Type );
9393 $params['type']->addCriteria( new CriterionInArray( self::getTypeNames() ) );
9494 $params['type']->addManipulations( new MapsParamGMap3Type() );
 95+ $params['type']->setDescription( wfMsg( 'maps-googlemaps3-par-type' ) );
9596
9697 $params['types'] = new ListParameter( 'types' );
9798 $params['types']->setDefault( $egMapsGMaps3Types );
9899 $params['types']->addCriteria( new CriterionInArray( self::getTypeNames() ) );
99100 $params['types']->addManipulations( new MapsParamGMap3Type() );
 101+ $params['types']->setDescription( wfMsg( 'maps-googlemaps3-par-types' ) );
100102
101103 $params['layers'] = new ListParameter( 'layers' );
102104 $params['layers']->setDefault( $egMapsGMaps3Layers );
103 - $params['layers']->addCriteria( new CriterionInArray( self::getLayerNames() ) );
 105+ $params['layers']->addCriteria( new CriterionInArray( self::getLayerNames() ) );
 106+ $params['layers']->setDescription( wfMsg( 'maps-googlemaps3-par-layers' ) );
104107
105108 $params['controls'] = new ListParameter( 'controls' );
106109 $params['controls']->setDefault( $egMapsGMaps3Controls );
107110 $params['controls']->addCriteria( new CriterionInArray( self::$controlNames ) );
108111 $params['controls']->addManipulations( new ParamManipulationFunctions( 'strtolower' ) );
 112+ $params['controls']->setDescription( wfMsg( 'maps-googlemaps3-par-controls' ) );
109113
110114 $params['zoomstyle'] = new Parameter( 'zoomstyle' );
111115 $params['zoomstyle']->setDefault( $egMapsGMaps3DefZoomStyle );
112116 $params['zoomstyle']->addCriteria( new CriterionInArray( 'default', 'small', 'large' ) );
113117 $params['zoomstyle']->addManipulations( new MapsParamGMap3Zoomstyle() );
 118+ $params['zoomstyle']->setDescription( wfMsg( 'maps-googlemaps3-par-zoomstyle' ) );
114119
115120 $params['typestyle'] = new Parameter( 'typestyle' );
116121 $params['typestyle']->setDefault( $egMapsGMaps3DefTypeStyle );
117122 $params['typestyle']->addCriteria( new CriterionInArray( array_keys( self::$tyepControlStyles ) ) );
118123 $params['typestyle']->addManipulations( new MapsParamGMap3Typestyle() );
 124+ $params['type']->setDescription( wfMsg( 'maps-googlemaps3-par-type' ) );
119125
120126 $params['autoinfowindows'] = new Parameter( 'autoinfowindows', Parameter::TYPE_BOOLEAN );
121127 $params['autoinfowindows']->setDefault( $egMapsGMaps3AutoInfoWindows );
 128+ $params['autoinfowindows']->setDescription( wfMsg( 'maps-googlemaps3-par-autoinfowindows' ) );
122129
123130 $params['kml'] = new ListParameter( 'kml' );
124131 $params['kml']->setDefault( array() );
125132 //$params['kml']->addManipulations( new MapsParamFile() );
 133+ $params['kml']->setDescription( wfMsg( 'maps-googlemaps3-par-kml' ) );
126134
127135 $params['fusiontables'] = new ListParameter( 'fusiontables' );
128136 $params['fusiontables']->setDefault( array() );
 137+ $params['fusiontables']->setDescription( wfMsg( 'maps-googlemaps3-par-fusiontables' ) );
129138
130139 $params['resizable'] = new Parameter( 'resizable', Parameter::TYPE_BOOLEAN );
131 - $params['resizable']->setDefault( $egMapsResizableByDefault, false );
 140+ $params['resizable']->setDefault( $egMapsResizableByDefault, false );
 141+ $params['resizable']->setDescription( wfMsg( 'maps-googlemaps3-par-resizable' ) );
132142 }
133143
134144 /**

Status & tagging log