Index: trunk/extensions/Translate/Translate.css |
— | — | @@ -180,3 +180,9 @@ |
181 | 181 | -webkit-border-radius: 10px; |
182 | 182 | background-color: #D1E231 !important; |
183 | 183 | } |
| 184 | + |
| 185 | +/* Quickedit */ |
| 186 | + |
| 187 | +.mw-translate-history { |
| 188 | + float: right; |
| 189 | +} |
\ No newline at end of file |
Index: trunk/extensions/Translate/js/quickedit.js |
— | — | @@ -49,6 +49,10 @@ |
50 | 50 | return false; |
51 | 51 | }); |
52 | 52 | |
| 53 | + form.find( ".mw-translate-history" ).click( function() { |
| 54 | + window.open( wgServer + wgScript + "?action=history&title=" + form.find( "input[name=title]" ).val() ); |
| 55 | + return false; |
| 56 | + }); |
53 | 57 | |
54 | 58 | form.find( ".mw-translate-edit-area" ).focus(); |
55 | 59 | |
Index: trunk/extensions/Translate/utils/TranslationEditPage.php |
— | — | @@ -68,6 +68,11 @@ |
69 | 69 | $save = Xml::submitButton( wfMsg( 'savearticle' ), array( 'style' => 'font-weight:bold' ) ); |
70 | 70 | $saveAndNext = Xml::submitButton( wfMsg( 'translate-js-next' ), array( 'class' => 'mw-translate-next' ) ); |
71 | 71 | $skip = Html::element( 'input', array( 'class' => 'mw-translate-skip', 'type' => 'button', 'value' => wfMsg( 'translate-js-skip' ) ) ); |
| 72 | + if ( $this->getTitle()->exists() ) { |
| 73 | + $history = Html::element( 'input', array( 'class' => 'mw-translate-history', 'type' => 'button', 'value' => wfMsg( 'translate-js-history' ) ) ); |
| 74 | + } else { |
| 75 | + $history = ''; |
| 76 | + } |
72 | 77 | |
73 | 78 | // Use the api to submit edits |
74 | 79 | $formParams = array( |
— | — | @@ -78,7 +83,7 @@ |
79 | 84 | $form = Html::rawElement( 'form', $formParams, |
80 | 85 | implode( "\n", $hidden ) . "\n" . |
81 | 86 | $helpers->getBoxes() . "\n" . |
82 | | - "$textarea\n$summary$save$saveAndNext$skip" |
| 87 | + "$textarea\n$summary$save$saveAndNext$skip$history" |
83 | 88 | ); |
84 | 89 | |
85 | 90 | echo $form; |
Index: trunk/extensions/Translate/Translate.i18n.php |
— | — | @@ -309,6 +309,7 @@ |
310 | 310 | 'translate-js-nonext' => 'This was the last message on this page.', |
311 | 311 | 'translate-js-skip' => 'Skip to next', |
312 | 312 | 'translate-js-save-failed' => 'Saving failed. Please report this error.', |
| 313 | + 'translate-js-history' => 'Translation history', |
313 | 314 | |
314 | 315 | // scripts/groupStatistics.php related messages |
315 | 316 | 'translate-gs-pos' => 'Pos.', |