Index: trunk/extensions/Translate/utils/TranslationHelpers.php |
— | — | @@ -643,8 +643,8 @@ |
644 | 644 | |
645 | 645 | $dialogID = $this->dialogID(); |
646 | 646 | $id = Sanitizer::escapeId( "def-$dialogID" ); |
647 | | - $msg = $this->adder( $id ) . "\n" . Html::rawElement( 'span', |
648 | | - array( 'class' => 'mw-translate-edit-deftext' ), |
| 647 | + $msg = $this->adder( $id ) . "\n" . Html::rawElement( 'div', |
| 648 | + array( 'class' => 'mw-translate-edit-deftext', 'dir' => 'ltr', 'lang' => 'en' ), |
649 | 649 | TranslateUtils::convertWhiteSpaceToHTML( $en ) |
650 | 650 | ); |
651 | 651 | |
— | — | @@ -749,7 +749,7 @@ |
750 | 750 | $params = array( 'class' => 'mw-translate-edit-item' ); |
751 | 751 | |
752 | 752 | $display = TranslateUtils::convertWhiteSpaceToHTML( $text ); |
753 | | - $display = Html::rawElement( 'span', array( |
| 753 | + $display = Html::rawElement( 'div', array( |
754 | 754 | 'lang' => $fbcode, |
755 | 755 | 'dir' => Language::factory( $fbcode )->getDir() ), |
756 | 756 | $display |
— | — | @@ -807,7 +807,8 @@ |
808 | 808 | $contents = preg_replace( '~^<([a-z]+)>(.*)</\1>$~us', '\2', $contents ); |
809 | 809 | |
810 | 810 | return TranslateUtils::fieldset( |
811 | | - wfMsgHtml( 'translate-edit-information', $edit, $page ), $contents, array( 'class' => $class ) |
| 811 | + wfMsgHtml( 'translate-edit-information', $edit, $page ), Html::rawElement( 'span', |
| 812 | + array( 'dir' => 'ltr', 'lang' => 'en' ), $contents ), array( 'class' => $class ) |
812 | 813 | ); |
813 | 814 | |
814 | 815 | } |
— | — | @@ -1074,7 +1075,9 @@ |
1075 | 1076 | $counter++; |
1076 | 1077 | $dialogID = $this->dialogID(); |
1077 | 1078 | $id = Sanitizer::escapeId( "tmsug-$dialogID-$counter" ); |
1078 | | - $contents = TranslateUtils::convertWhiteSpaceToHTML( $text ); |
| 1079 | + $contents = Html::rawElement( 'div', array( 'lang' => $this->targetLanguage, |
| 1080 | + 'dir' => Language::factory( $this->targetLanguage )->getDir() ), |
| 1081 | + TranslateUtils::convertWhiteSpaceToHTML( $text ) ); |
1079 | 1082 | $contents .= $this->wrapInsert( $id, $text ); |
1080 | 1083 | |
1081 | 1084 | return $this->adder( $id ) . "\n" . $contents; |