http://www.mediawiki.org/wiki/Special:Code/MediaWiki/73776
Revision: 73776
Author: jeroendedauw
Date: 2010-09-26 15:26:19 +0000 (Sun, 26 Sep 2010)
Log Message:
-----------
CHanges for 0.7 - fixed issue with width and height parameters
Modified Paths:
--------------
trunk/extensions/Maps/Maps.php
trunk/extensions/Maps/includes/manipulations/Maps_ParamDimension.php
trunk/extensions/Maps/includes/services/GoogleMaps/Maps_GoogleMapsDispMap.php
Modified: trunk/extensions/Maps/Maps.php
===================================================================
--- trunk/extensions/Maps/Maps.php 2010-09-26 13:56:27 UTC (rev 73775)
+++ trunk/extensions/Maps/Maps.php 2010-09-26 15:26:19 UTC (rev 73776)
@@ -49,7 +49,8 @@
define( 'Maps_GEO_MIN', "'" );
define( 'Maps_GEO_SEC', '"' );
- $useExtensionPath = version_compare( $wgVersion, '1.16', '>=' ) &&
isset( $wgExtensionAssetsPath ) && $wgExtensionAssetsPath;
+ // TODO
+ $useExtensionPath = /*version_compare( $wgVersion, '1.16', '>=' ) &&*/
isset( $wgExtensionAssetsPath ) && $wgExtensionAssetsPath;
$egMapsScriptPath = ( $useExtensionPath ? $wgExtensionAssetsPath
: $wgScriptPath . '/extensions' ) . '/Maps';
$egMapsDir = dirname( __FILE__ ) . '/';
unset( $useExtensionPath );
Modified: trunk/extensions/Maps/includes/manipulations/Maps_ParamDimension.php
===================================================================
--- trunk/extensions/Maps/includes/manipulations/Maps_ParamDimension.php
2010-09-26 13:56:27 UTC (rev 73775)
+++ trunk/extensions/Maps/includes/manipulations/Maps_ParamDimension.php
2010-09-26 15:26:19 UTC (rev 73776)
@@ -69,6 +69,10 @@
} else if ( $number > $max ) {
$value = $max;
}
+
+ if ( !preg_match( '/(px|ex|em|%)$/', $value ) ) {
+ $value .= 'px';
+ }
}
}
\ No newline at end of file
Modified:
trunk/extensions/Maps/includes/services/GoogleMaps/Maps_GoogleMapsDispMap.php
===================================================================
---
trunk/extensions/Maps/includes/services/GoogleMaps/Maps_GoogleMapsDispMap.php
2010-09-26 13:56:27 UTC (rev 73775)
+++
trunk/extensions/Maps/includes/services/GoogleMaps/Maps_GoogleMapsDispMap.php
2010-09-26 15:26:19 UTC (rev 73776)
@@ -1,25 +1,13 @@
<?php
/**
- * Class for handling the display_map parser function with Google Maps
+ * Class for handling the display_map parser functions with Google Maps.
*
* @file Maps_GoogleMapsDispMap.php
* @ingroup MapsGoogleMaps
*
* @author Jeroen De Dauw
*/
-
-if ( !defined( 'MEDIAWIKI' ) ) {
- die( 'Not an entry point.' );
-}
-
-/**
- * Class for handling the display_map parser functions with Google Maps.
- *
- * @ingroup MapsGoogleMaps
- *
- * @author Jeroen De Dauw
- */
final class MapsGoogleMapsDispMap extends MapsBaseMap {
protected function initSpecificParamInfo( array &$parameters ) {
_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs