Index: trunk/phase3/includes/diff/DifferenceEngine.php |
— | — | @@ -25,7 +25,7 @@ |
26 | 26 | var $mOldid, $mNewid; |
27 | 27 | var $mOldtitle, $mNewtitle, $mPagetitle; |
28 | 28 | var $mOldtext, $mNewtext; |
29 | | - var $mDiffLang; |
| 29 | + protected $mDiffLang; |
30 | 30 | |
31 | 31 | /** |
32 | 32 | * @var Title |
— | — | @@ -981,7 +981,7 @@ |
982 | 982 | * (Defaults to page content language). |
983 | 983 | * @since 1.19 |
984 | 984 | */ |
985 | | - function setDiffLang( $lang ) { |
| 985 | + function setTextLanguage( $lang ) { |
986 | 986 | $this->mDiffLang = wfGetLangObj( $lang ); |
987 | 987 | } |
988 | 988 | |
Index: trunk/extensions/Translate/tag/SpecialPageTranslation.php |
— | — | @@ -380,8 +380,8 @@ |
381 | 381 | |
382 | 382 | if ( $s->type === 'changed' ) { |
383 | 383 | $diff = new DifferenceEngine; |
384 | | - if ( method_exists( 'DifferenceEngine', 'setDiffLang' ) ) { |
385 | | - $diff->setDiffLang( $wgContLang ); |
| 384 | + if ( method_exists( 'DifferenceEngine', 'setTextLanguage' ) ) { |
| 385 | + $diff->setTextLanguage( $wgContLang ); |
386 | 386 | } |
387 | 387 | $diff->setText( $s->getOldText(), $s->getText() ); |
388 | 388 | $text = $diff->getDiff( wfMsgHtml( 'tpt-diff-old' ), wfMsgHtml( 'tpt-diff-new' ) ); |
— | — | @@ -394,7 +394,7 @@ |
395 | 395 | $text = TranslateUtils::convertWhiteSpaceToHTML( $s->getText() ); |
396 | 396 | } |
397 | 397 | |
398 | | - # For changed text, the language is set by $diff->setDiffLang() |
| 398 | + # For changed text, the language is set by $diff->setTextLanguage() |
399 | 399 | $lang = $s->type === 'changed' ? null : $wgContLang; |
400 | 400 | $wgOut->addHTML( MessageWebImporter::makeSectionElement( $name, $s->type, $text, $lang ) ); |
401 | 401 | } |
— | — | @@ -420,8 +420,8 @@ |
421 | 421 | $wgOut->wrapWikiMsg( '==$1==', 'tpt-sections-template' ); |
422 | 422 | |
423 | 423 | $diff = new DifferenceEngine; |
424 | | - if ( method_exists( 'DifferenceEngine', 'setDiffLang' ) ) { |
425 | | - $diff->setDiffLang( $wgContLang ); |
| 424 | + if ( method_exists( 'DifferenceEngine', 'setTextLanguage' ) ) { |
| 425 | + $diff->setTextLanguage( $wgContLang ); |
426 | 426 | } |
427 | 427 | $diff->setText( $oldTemplate, $newTemplate ); |
428 | 428 | $text = $diff->getDiff( wfMsgHtml( 'tpt-diff-old' ), wfMsgHtml( 'tpt-diff-new' ) ); |
Index: trunk/extensions/Translate/utils/TranslationHelpers.php |
— | — | @@ -901,8 +901,8 @@ |
902 | 902 | } |
903 | 903 | |
904 | 904 | $diff = new DifferenceEngine; |
905 | | - if ( method_exists( 'DifferenceEngine', 'setDiffLang' ) ) { |
906 | | - $diff->setDiffLang( $this->group->getSourceLanguage() ); |
| 905 | + if ( method_exists( 'DifferenceEngine', 'setTextLanguage' ) ) { |
| 906 | + $diff->setTextLanguage( $this->group->getSourceLanguage() ); |
907 | 907 | } |
908 | 908 | $diff->setText( $oldtext, $newtext ); |
909 | 909 | $diff->setReducedLineNumbers(); |
— | — | @@ -953,8 +953,8 @@ |
954 | 954 | } |
955 | 955 | |
956 | 956 | $diff = new DifferenceEngine; |
957 | | - if ( method_exists( 'DifferenceEngine', 'setDiffLang' ) ) { |
958 | | - $diff->setDiffLang( $this->group->getSourceLanguage() ); |
| 957 | + if ( method_exists( 'DifferenceEngine', 'setTextLanguage' ) ) { |
| 958 | + $diff->setTextLanguage( $this->group->getSourceLanguage() ); |
959 | 959 | } |
960 | 960 | $diff->setText( $oldtext, $newtext ); |
961 | 961 | $diff->setReducedLineNumbers(); |