Index: trunk/extensions/Translate/js/quickedit.js |
— | — | @@ -11,13 +11,11 @@ |
12 | 12 | * |
13 | 13 | * TODO list: |
14 | 14 | * * On succesful save, update the MessageTable display too. |
15 | | - * * Integrate the (new) edittoolbar |
16 | 15 | * * Autoload ui classes |
17 | 16 | * * Instead of hc'd onscript, give them a class and use necessary triggers |
18 | | - * * Live-update the checks assistant |
19 | 17 | * |
20 | 18 | * @author Niklas Laxström |
21 | | - * @copyright Copyright © 2009-2010 Niklas Laxström |
| 19 | + * @copyright Copyright © 2009-2011 Niklas Laxström |
22 | 20 | * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later |
23 | 21 | */ |
24 | 22 | |
— | — | @@ -152,11 +150,11 @@ |
153 | 151 | if ( json.error ) { |
154 | 152 | alert( json.error.info + ' (' + json.error.code +')' ); |
155 | 153 | } else if ( json.edit.result === 'Failure' ) { |
156 | | - alert( trlMsgSaveFailed ); |
| 154 | + alert( mw.msg( 'translate-js-save-failed' ) ); |
157 | 155 | } else if ( json.edit.result === 'Success' ) { |
158 | 156 | dialog.dialog( 'close' ); |
159 | 157 | } else { |
160 | | - alert( trlMsgSaveFailed ); |
| 158 | + alert( mw.msg( 'translate-js-save-failed' ) ); |
161 | 159 | } |
162 | 160 | } |
163 | 161 | } ); |
— | — | @@ -197,7 +195,7 @@ |
198 | 196 | found = true; |
199 | 197 | } |
200 | 198 | } |
201 | | - alert(trlMsgNoNext); |
| 199 | + alert( mw.msg( 'translate-js-nonext' ) ); |
202 | 200 | return; |
203 | 201 | } |
204 | 202 | |
Index: trunk/extensions/Translate/Translate.php |
— | — | @@ -143,6 +143,7 @@ |
144 | 144 | $wgResourceModules['ext.translate.quickedit'] = array( |
145 | 145 | 'scripts' => 'js/quickedit.js', |
146 | 146 | 'styles' => 'js/ext.translate.quickedit.css', |
| 147 | + 'messages' => array( 'translate-js-nonext', 'translate-js-save-failed' ), |
147 | 148 | ) + $resourcePaths; |
148 | 149 | |
149 | 150 | $wgResourceModules['ext.translate.messagetable'] = array( |
Index: trunk/extensions/Translate/utils/TranslationHelpers.php |
— | — | @@ -1213,13 +1213,6 @@ |
1214 | 1214 | $out->addExtensionStyle( TranslateUtils::assetPath( 'js/base/custom-theme/jquery-ui-1.7.2.custom.css' ) ); |
1215 | 1215 | } |
1216 | 1216 | |
1217 | | - $vars = array( |
1218 | | - 'trlMsgNoNext' => wfMsg( 'translate-js-nonext' ), |
1219 | | - 'trlMsgSaveFailed' => wfMsg( 'translate-js-save-failed' ), |
1220 | | - ); |
1221 | | - |
1222 | | - $out->addScript( Skin::makeVariablesScript( $vars ) ); |
1223 | | - |
1224 | 1217 | // Might be needed, but ajax doesn't load it |
1225 | 1218 | // Globals :( |
1226 | 1219 | $diff = new DifferenceEngine; |