Index: trunk/extensions/ParserFunctions/Convert.php |
— | — | @@ -135,8 +135,8 @@ |
136 | 136 | if( $this->targetUnit->dimension->value != $this->sourceUnit->dimension->value ){ |
137 | 137 | throw new ConvertError( |
138 | 138 | 'dimensionmismatch', |
139 | | - $this->sourceUnit->dimension->getName(true), |
140 | | - $this->targetUnit->dimension->getName(true) |
| 139 | + $this->sourceUnit->dimension->getLocalisedName(true), |
| 140 | + $this->targetUnit->dimension->getLocalisedName(true) |
141 | 141 | ); |
142 | 142 | } |
143 | 143 | |
— | — | @@ -206,8 +206,8 @@ |
207 | 207 | } else { |
208 | 208 | # Need to round to a similar accuracy as the original value. To do that we |
209 | 209 | # select the accuracy which will as closely as possible preserve the maximum |
210 | | - # percentage error in the value. So 36ft = 36 � 0.5 ft, so the uncertainty |
211 | | - # is �0.5/36 = �1.4%. In metres this is 10.9728 � 1.4%, or 10.9728 � 0.154 |
| 210 | + # percentage error in the value. So 36ft = 36 ± 0.5 ft, so the uncertainty |
| 211 | + # is ±0.5/36 = ±1.4%. In metres this is 10.9728 ± 1.4%, or 10.9728 ± 0.154 |
212 | 212 | # we take the stance of choosing the limit which is *more* precise than the |
213 | 213 | # original value. |
214 | 214 | |
— | — | @@ -698,7 +698,7 @@ |
699 | 699 | if( $link && !wfEmptyMsg( "$msg-link" ) ){ |
700 | 700 | $title = Title::newFromText( wfMsgForContentNoTrans( "$msg-link" ) ); |
701 | 701 | if( $title instanceof Title ){ |
702 | | - $msgText = "[[$title|$msgText]]"; |
| 702 | + $msgText = "[[{$title->getFullText()}|$msgText]]"; |
703 | 703 | } |
704 | 704 | } |
705 | 705 | |
Index: trunk/extensions/ParserFunctions/ParserFunctions.i18n.magic.php |
— | — | @@ -23,12 +23,12 @@ |
24 | 24 | 'rel2abs' => array( 0, 'rel2abs' ), |
25 | 25 | 'titleparts' => array( 0, 'titleparts' ), |
26 | 26 | 'convert' => array( 0, 'convert' ), |
27 | | - 'sourceunit' => array( 0, '#sourceunit' ), |
28 | | - 'targetunit' => array( 0, '#targetunit' ), |
29 | | - 'linkunit' => array( 0, '#linkunit' ), |
30 | | - 'decimalplaces' => array( 0, '#dp' ), |
31 | | - 'significantfigures' => array( 0, '#sf' ), |
32 | | - 'abbreviate' => array( 0, '#abbreviate' ), |
| 27 | + 'sourceunit' => array( 0, '#sourceunit' ), |
| 28 | + 'targetunit' => array( 0, '#targetunit' ), |
| 29 | + 'linkunit' => array( 0, '#linkunit' ), |
| 30 | + 'decimalplaces' => array( 0, '#dp' ), |
| 31 | + 'significantfigures' => array( 0, '#sf' ), |
| 32 | + 'abbreviate' => array( 0, '#abbreviate' ), |
33 | 33 | 'len' => array( 0, 'len' ), |
34 | 34 | 'pos' => array( 0, 'pos' ), |
35 | 35 | 'rpos' => array( 0, 'rpos' ), |
Index: trunk/extensions/ParserFunctions/ParserFunctions_body.php |
— | — | @@ -52,9 +52,6 @@ |
53 | 53 | */ |
54 | 54 | function &getExprParser() { |
55 | 55 | if ( !isset( $this->mExprParser ) ) { |
56 | | - if ( !class_exists( 'ExprParser' ) ) { |
57 | | - require( dirname( __FILE__ ) . '/Expr.php' ); |
58 | | - } |
59 | 56 | $this->mExprParser = new ExprParser; |
60 | 57 | } |
61 | 58 | return $this->mExprParser; |
— | — | @@ -518,9 +515,6 @@ |
519 | 516 | */ |
520 | 517 | protected function &getConvertParser() { |
521 | 518 | if ( !isset( $this->mConvertParser ) ) { |
522 | | - if ( !class_exists( 'ConvertParser' ) ) { |
523 | | - require( dirname( __FILE__ ) . '/Convert.php' ); |
524 | | - } |
525 | 519 | $this->mConvertParser = new ConvertParser; |
526 | 520 | } |
527 | 521 | return $this->mConvertParser; |
Index: trunk/extensions/ParserFunctions/ParserFunctions.php |
— | — | @@ -41,6 +41,9 @@ |
42 | 42 | ); |
43 | 43 | |
44 | 44 | $wgAutoloadClasses['ExtParserFunctions'] = dirname( __FILE__ ) . '/ParserFunctions_body.php'; |
| 45 | +$wgAutoloadClasses['ExprParser'] = dirname( __FILE__ ) . '/Expr.php'; |
| 46 | +$wgAutoloadClasses['ConvertParser'] = dirname( __FILE__ ) . '/Convert.php'; |
| 47 | + |
45 | 48 | $wgExtensionMessagesFiles['ParserFunctions'] = dirname( __FILE__ ) . '/ParserFunctions.i18n.php'; |
46 | 49 | $wgExtensionMessagesFiles['ParserFunctionsMagic'] = dirname( __FILE__ ) . '/ParserFunctions.i18n.magic.php'; |
47 | 50 | |