Index: trunk/extensions/LiquidThreads/LiquidThreads.php |
— | — | @@ -69,7 +69,7 @@ |
70 | 70 | ); |
71 | 71 | |
72 | 72 | $wgResourceModules['ext.liquidThreads'] = $lqtResourceTemplate + array( |
73 | | - 'styles' => array( 'lqt.css', 'jquery/jquery.thread_collapse.css' ), |
| 73 | + 'styles' => array( 'lqt.css', 'jquery/jquery.thread_collapse.css', 'lqt.dialogs.css' ), |
74 | 74 | 'scripts' => array( 'lqt.js', 'js/lqt.toolbar.js', 'jquery/jquery.thread_collapse.js', 'jquery/jquery.autogrow.js' ), |
75 | 75 | 'dependencies' => array( 'jquery.ui.dialog' ), |
76 | 76 | 'messages' => $lqtMessages |
Index: trunk/extensions/LiquidThreads/lqt.dialogs.css |
— | — | @@ -0,0 +1,207 @@ |
| 2 | +/* |
| 3 | + * CSS for WikiEditor Dialogs |
| 4 | + */ |
| 5 | + |
| 6 | +/* Table Dialog */ |
| 7 | +#wikieditor-toolbar-table-dialog fieldset { |
| 8 | + width: 218px; |
| 9 | + padding: 0; |
| 10 | + float: left; |
| 11 | +} |
| 12 | +body.rtl #wikieditor-toolbar-table-dialog fieldset { |
| 13 | + float: right; |
| 14 | +} |
| 15 | +#wikieditor-toolbar-table-dialog .wikieditor-toolbar-table-preview-wrapper { |
| 16 | + width: 330px; |
| 17 | + padding: 0; |
| 18 | + float: right; |
| 19 | +} |
| 20 | +body.rtl #wikieditor-toolbar-table-dialog .wikieditor-toolbar-table-preview-wrapper { |
| 21 | + float: left; |
| 22 | +} |
| 23 | +body.rtl .wikiEditor-toolbar-dialog .wikieditor-toolbar-table-preview-wrapper table { |
| 24 | + margin-left: 1em; |
| 25 | + margin-right: 0; |
| 26 | +} |
| 27 | +.wikieditor-toolbar-table-preview-content * { |
| 28 | + cursor: default; |
| 29 | +} |
| 30 | +.wikiEditor-toolbar-dialog .wikieditor-toolbar-table-preview-wrapper table { |
| 31 | + width: 100% !important; |
| 32 | +} |
| 33 | +.wikiEditor-toolbar-dialog .wikieditor-toolbar-table-preview-content table td { |
| 34 | + padding: 10px 4px !important; |
| 35 | + height: auto !important; |
| 36 | +} |
| 37 | +.wikiEditor-toolbar-dialog .wikieditor-toolbar-table-preview-content table th { |
| 38 | + padding: 7px 3px !important; |
| 39 | +} |
| 40 | +.wikieditor-toolbar-table-dimension-fields .wikieditor-toolbar-field-wrapper { |
| 41 | + float: left; |
| 42 | + margin-right: 20px; |
| 43 | + vertical-align: bottom; |
| 44 | +} |
| 45 | +body.rtl .wikieditor-toolbar-table-dimension-fields .wikieditor-toolbar-field-wrapper { |
| 46 | + float: right; |
| 47 | + margin-right: 0px; |
| 48 | + margin-left: 20px; |
| 49 | +} |
| 50 | +.wikiEditor-toolbar-dialog .ui-dialog-content { |
| 51 | + padding: 30px 20px 0 !important; |
| 52 | +} |
| 53 | +.wikieditor-toolbar-dialog-wrapper { |
| 54 | + width: 100%; |
| 55 | +} |
| 56 | +/* Insert Link Dialog */ |
| 57 | +#wikieditor-toolbar-link-int-target-status { |
| 58 | + float: right; |
| 59 | +} |
| 60 | +#wikieditor-toolbar-link-int-target, |
| 61 | +#wikieditor-toolbar-link-int-text { |
| 62 | + width: 100%; |
| 63 | +} |
| 64 | +#wikieditor-toolbar-tool-link-int-target-label { |
| 65 | + float: left; |
| 66 | + line-height: 1.7em; |
| 67 | +} |
| 68 | +#wikieditor-toolbar-link-int-target-status-loading { |
| 69 | + line-height: 1.7em; |
| 70 | +} |
| 71 | +#wikieditor-toolbar-link-int-target-status-exists, |
| 72 | +#wikieditor-toolbar-link-int-target-status-notexists, |
| 73 | +#wikieditor-toolbar-link-int-target-status-invalid, |
| 74 | +#wikieditor-toolbar-link-int-target-status-external { |
| 75 | + padding-left: 30px; |
| 76 | + background-position: 0 50%; |
| 77 | + background-repeat: no-repeat; |
| 78 | +} |
| 79 | +#wikieditor-toolbar-link-int-target-status-exists { |
| 80 | + /* @embed */ |
| 81 | + background-image: url(images/dialogs/insert-link-exists.png); |
| 82 | +} |
| 83 | +#wikieditor-toolbar-link-int-target-status-notexists { |
| 84 | + /* @embed */ |
| 85 | + background-image: url(images/dialogs/insert-link-notexists.png); |
| 86 | +} |
| 87 | +#wikieditor-toolbar-link-int-target-status-invalid { |
| 88 | + /* @embed */ |
| 89 | + background-image: url(images/dialogs/insert-link-invalid.png); |
| 90 | +} |
| 91 | +#wikieditor-toolbar-link-int-target-status-external { |
| 92 | + /* @embed */ |
| 93 | + background-image: url(images/dialogs/insert-link-external.png); |
| 94 | +} |
| 95 | +/* Reference Dialog */ |
| 96 | +#wikieditor-toolbar-reference-dialog label { |
| 97 | + float: left; |
| 98 | + line-height: 1.7em; |
| 99 | +} |
| 100 | +#wikieditor-toolbar-reference-text { |
| 101 | + width: 100%; |
| 102 | +} |
| 103 | +/* RTL Changes */ |
| 104 | +body.rtl .wikiEditor-toolbar-dialog .ui-dialog-buttonpane button { |
| 105 | + float: left; |
| 106 | + margin: 0.5em 0.4em 0.5em 0 !important; |
| 107 | +} |
| 108 | +body.rtl .wikiEditor-toolbar-dialog .ui-dialog-titlebar-close { |
| 109 | + left: 0.9em; |
| 110 | + right: auto; |
| 111 | +} |
| 112 | +body.rtl .wikiEditor-toolbar-dialog .ui-dialog-title { |
| 113 | + float:right; |
| 114 | +} |
| 115 | +body.rtl #wikieditor-toolbar-link-int-target-status { |
| 116 | + float: left; |
| 117 | +} |
| 118 | +body.rtl #wikieditor-toolbar-tool-link-int-target-label { |
| 119 | + float: right; |
| 120 | +} |
| 121 | +body.rtl .wikieditor-toolbar-floated-field-wrapper { |
| 122 | + float: right; |
| 123 | + margin-right: 0; |
| 124 | + margin-left: 2em; |
| 125 | +} |
| 126 | +body.rtl #wikieditor-toolbar-link-int-target-status-exists, |
| 127 | +body.rtl #wikieditor-toolbar-link-int-target-status-notexists, |
| 128 | +body.rtl #wikieditor-toolbar-link-int-target-status-invalid, |
| 129 | +body.rtl #wikieditor-toolbar-link-int-target-status-external { |
| 130 | + padding-left: 0; |
| 131 | + padding-right: 30px; |
| 132 | + background-position: 100% 50%; |
| 133 | +} |
| 134 | +body.rtl #wikieditor-toolbar-link-int-target-status-external { |
| 135 | + /* @embed */ |
| 136 | + background-image: url(images/dialogs/insert-link-external-rtl.png); |
| 137 | +} |
| 138 | +body.rtl #wikieditor-toolbar-reference-dialog label { |
| 139 | + float: right; |
| 140 | +} |
| 141 | +/* Template Editor Dialogs */ |
| 142 | +.wikiEditor-template-dialog-fields label { |
| 143 | + text-transform: capitalize; |
| 144 | + float: left; |
| 145 | + width: 25%; |
| 146 | + line-height: 2.25em; |
| 147 | +} |
| 148 | +.wikiEditor-template-dialog-fields textarea { |
| 149 | + float: right; |
| 150 | + width: 70%; |
| 151 | + line-height: 1.5em; |
| 152 | + height: 1.5em; |
| 153 | +} |
| 154 | +.wikiEditor-template-dialog-fields .wikiEditor-template-dialog-field-wrapper { |
| 155 | + padding: 0.75em 0.33em; |
| 156 | + border-bottom: dashed 1px silver; |
| 157 | + clear: both; |
| 158 | +} |
| 159 | +.wikiEditor-template-dialog-fields .wikiEditor-template-dialog-field-wrapper:first-child { |
| 160 | + padding-top: 0; |
| 161 | +} |
| 162 | +.wikiEditor-template-dialog-fields .wikiEditor-template-dialog-field-wrapper:last-child { |
| 163 | + border-bottom: none; |
| 164 | +} |
| 165 | +/* Self Clearing Floats */ |
| 166 | +.wikieditor-toolbar-table-dimension-fields:after, |
| 167 | +.wikieditor-toolbar-dialog-wrapper:after { |
| 168 | + visibility: hidden; |
| 169 | + display: block; |
| 170 | + font-size: 0; |
| 171 | + content: " "; |
| 172 | + clear: both; |
| 173 | + height: 0; |
| 174 | +} |
| 175 | +.wikieditor-toolbar-table-dimension-fields, |
| 176 | +.wikieditor-toolbar-dialog-wrapper { |
| 177 | + display: inline-table; |
| 178 | +} |
| 179 | +/* Hides from IE-mac \*/ |
| 180 | +* html .wikieditor-toolbar-table-dimension-fields, |
| 181 | +* html .wikieditor-toolbar-dialog-wrapper { |
| 182 | + height: 1%; |
| 183 | +} |
| 184 | +.wikieditor-toolbar-table-dimension-fields, |
| 185 | +.wikieditor-toolbar-dialog-wrapper { |
| 186 | + display: block; |
| 187 | +} |
| 188 | +/* End hide from IE-mac */ |
| 189 | +.wikiEditor-toolbar-dialog .ui-dialog-buttonpane { |
| 190 | + border-top: 1px solid #cccccc !important; |
| 191 | +} |
| 192 | +.wikiEditor-toolbar-dialog .ui-dialog-content { |
| 193 | + padding-bottom: 1em !important; |
| 194 | +} |
| 195 | +/* Edit dialog */ |
| 196 | +.wikiEditor-dialog-editoptions { |
| 197 | + margin-top: 15px; |
| 198 | +} |
| 199 | +/* Publish dialog */ |
| 200 | +.wikiEditor-publish-dialog-copywarn { |
| 201 | + margin-top: 0.5em; |
| 202 | +} |
| 203 | +.wikiEditor-publish-dialog-summary { |
| 204 | + margin-top: 1.5em; |
| 205 | +} |
| 206 | +.wikiEditor-publish-dialog-options { |
| 207 | + margin-top: 1.5em; |
| 208 | +} |
Property changes on: trunk/extensions/LiquidThreads/lqt.dialogs.css |
___________________________________________________________________ |
Added: svn:eol-style |
1 | 209 | + native |
Index: trunk/extensions/LiquidThreads/lqt.js |
— | — | @@ -193,7 +193,7 @@ |
194 | 194 | if ( typeof wgWikiEditorPreferences != 'undefined' ) { |
195 | 195 | useDialogs = wgWikiEditorPreferences.toolbar.dialogs; |
196 | 196 | } else { |
197 | | - useDialogs = mediaWiki.user.options['usebetatoolbar-cgd']; |
| 197 | + useDialogs = mediaWiki.user.options.get( 'usebetatoolbar-cgd' ); |
198 | 198 | } |
199 | 199 | |
200 | 200 | if ( useDialogs && $j.wikiEditor.isSupported( $j.wikiEditor.modules.dialogs ) ) { |
— | — | @@ -202,13 +202,14 @@ |
203 | 203 | |
204 | 204 | // Add wikiEditor toolbar |
205 | 205 | $j( '#wpTextbox1' ).wikiEditor( 'addModule', { 'toolbar': liquidThreads.toolbar.config, 'dialogs': liquidThreads.toolbar.dialogs } ); |
| 206 | + |
206 | 207 | |
207 | 208 | // cleanup unnecessary things from the old toolbar |
208 | 209 | $j( '#editpage-specialchars' ).remove(); |
209 | | - $j( '#wpTextbox1' ).focus() |
| 210 | + $j( '#wpTextbox1' ).focus(); |
210 | 211 | } else { |
211 | 212 | // Add old toolbar |
212 | | - mwSetupToolbar() |
| 213 | + mwSetupToolbar(); |
213 | 214 | } |
214 | 215 | currentFocused = $j(container).find('#wpTextbox1'); |
215 | 216 | $j(container).find('#wpTextbox1,#wpSummary').focus( |
— | — | @@ -229,7 +230,7 @@ |
230 | 231 | if ( typeof mediaWiki.loader != 'undefined' && mediaWiki.loader ) { |
231 | 232 | mediaWiki.loader.using( |
232 | 233 | [ 'ext.wikiEditor', 'ext.wikiEditor.toolbar.i18n', |
233 | | - 'jquery.wikiEditor.toolbar', |
| 234 | + 'jquery.wikiEditor.toolbar', 'jquery.wikiEditor.dialogs', |
234 | 235 | 'jquery.async', 'jquery.cookie' ], |
235 | 236 | finishSetup ); |
236 | 237 | } else { |
Index: trunk/extensions/LiquidThreads/js/lqt.toolbar.js |
— | — | @@ -1059,20 +1059,19 @@ |
1060 | 1060 | updateExistence( true ); |
1061 | 1061 | }); |
1062 | 1062 | // Set labels of tabs based on rel values |
1063 | | - var u = mw.usability; |
1064 | 1063 | $j(this).find( '[rel]' ).each( function() { |
1065 | | - $j(this).text( u.getMsg( $j(this).attr( 'rel' ) ) ); |
| 1064 | + $j(this).text( mediaWiki.msg( $j(this).attr( 'rel' ) ) ); |
1066 | 1065 | }); |
1067 | 1066 | // Set tabindexes on form fields |
1068 | 1067 | $j.wikiEditor.modules.dialogs.fn.setTabindexes( $j(this).find( 'input' ).not( '[tabindex]' ) ); |
1069 | 1068 | // Setup the tooltips in the textboxes |
1070 | 1069 | $j( '#wikieditor-toolbar-link-int-target' ) |
1071 | | - .data( 'tooltip', u.getMsg( 'wikieditor-toolbar-tool-link-int-target-tooltip' ) ); |
| 1070 | + .data( 'tooltip', mediaWiki.msg( 'wikieditor-toolbar-tool-link-int-target-tooltip' ) ); |
1072 | 1071 | $j( '#wikieditor-toolbar-link-int-text' ) |
1073 | | - .data( 'tooltip', u.getMsg( 'wikieditor-toolbar-tool-link-int-text-tooltip' ) ); |
| 1072 | + .data( 'tooltip', mediaWiki.msg( 'wikieditor-toolbar-tool-link-int-text-tooltip' ) ); |
1074 | 1073 | $j( '#wikieditor-toolbar-link-int-target, #wikieditor-toolbar-link-int-text' ) |
1075 | 1074 | .each( function() { |
1076 | | - var tooltip = u.getMsg( $j( this ).attr( 'id' ) + '-tooltip' ); |
| 1075 | + var tooltip = mediaWiki.msg( $j( this ).attr( 'id' ) + '-tooltip' ); |
1077 | 1076 | if ( $j( this ).val() == '' ) |
1078 | 1077 | $j( this ) |
1079 | 1078 | .addClass( 'wikieditor-toolbar-dialog-hint' ) |
— | — | @@ -1142,11 +1141,11 @@ |
1143 | 1142 | }); |
1144 | 1143 | // Add images to the page existence widget, which will be shown mutually exclusively to communicate if the |
1145 | 1144 | // page exists, does not exist or the title is invalid (like if it contains a | character) |
1146 | | - var existsMsg = u.getMsg( 'wikieditor-toolbar-tool-link-int-target-status-exists' ); |
1147 | | - var notexistsMsg = u.getMsg( 'wikieditor-toolbar-tool-link-int-target-status-notexists' ); |
1148 | | - var invalidMsg = u.getMsg( 'wikieditor-toolbar-tool-link-int-target-status-invalid' ); |
1149 | | - var externalMsg = u.getMsg( 'wikieditor-toolbar-tool-link-int-target-status-external' ); |
1150 | | - var loadingMsg = u.getMsg( 'wikieditor-toolbar-tool-link-int-target-status-loading' ); |
| 1145 | + var existsMsg = mediaWiki.msg( 'wikieditor-toolbar-tool-link-int-target-status-exists' ); |
| 1146 | + var notexistsMsg = mediaWiki.msg( 'wikieditor-toolbar-tool-link-int-target-status-notexists' ); |
| 1147 | + var invalidMsg = mediaWiki.msg( 'wikieditor-toolbar-tool-link-int-target-status-invalid' ); |
| 1148 | + var externalMsg = mediaWiki.msg( 'wikieditor-toolbar-tool-link-int-target-status-external' ); |
| 1149 | + var loadingMsg = mediaWiki.msg( 'wikieditor-toolbar-tool-link-int-target-status-loading' ); |
1151 | 1150 | $j( '#wikieditor-toolbar-link-int-target-status' ) |
1152 | 1151 | .append( $j( '<div />' ) |
1153 | 1152 | .attr( 'id', 'wikieditor-toolbar-link-int-target-status-exists' ) |
— | — | @@ -1263,9 +1262,8 @@ |
1264 | 1263 | target = ""; |
1265 | 1264 | if ( $j( '#wikieditor-toolbar-link-int-text' ).data( 'tooltip-mode' ) ) |
1266 | 1265 | text = ""; |
1267 | | - var u = mw.usability; |
1268 | 1266 | if ( target == '' ) { |
1269 | | - alert( u.getMsg( 'wikieditor-toolbar-tool-link-empty' ) ); |
| 1267 | + alert( mediaWiki.msg( 'wikieditor-toolbar-tool-link-empty' ) ); |
1270 | 1268 | return; |
1271 | 1269 | } |
1272 | 1270 | if ( $j.trim( text ) == '' ) { |
— | — | @@ -1277,7 +1275,7 @@ |
1278 | 1276 | // FIXME: Exactly how fragile is this? |
1279 | 1277 | if ( $j( '#wikieditor-toolbar-link-int-target-status-invalid' ).is( ':visible' ) ) { |
1280 | 1278 | // Refuse to add links to invalid titles |
1281 | | - alert( u.getMsg( 'wikieditor-toolbar-tool-link-int-invalid' ) ); |
| 1279 | + alert( mediaWiki.msg( 'wikieditor-toolbar-tool-link-int-invalid' ) ); |
1282 | 1280 | return; |
1283 | 1281 | } |
1284 | 1282 | |
— | — | @@ -1295,18 +1293,18 @@ |
1296 | 1294 | if ( match && !$j(this).data( 'ignoreLooksInternal' ) ) { |
1297 | 1295 | var buttons = { }; |
1298 | 1296 | var that = this; |
1299 | | - buttons[ u.getMsg( 'wikieditor-toolbar-tool-link-lookslikeinternal-int' ) ] = function() { |
| 1297 | + buttons[ mediaWiki.msg( 'wikieditor-toolbar-tool-link-lookslikeinternal-int' ) ] = function() { |
1300 | 1298 | $j( '#wikieditor-toolbar-link-int-target' ).val( match[1] ).change(); |
1301 | 1299 | $j(this).dialog( 'close' ); |
1302 | 1300 | }; |
1303 | | - buttons[ u.getMsg( 'wikieditor-toolbar-tool-link-lookslikeinternal-ext' ) ] = function() { |
| 1301 | + buttons[ mediaWiki.msg( 'wikieditor-toolbar-tool-link-lookslikeinternal-ext' ) ] = function() { |
1304 | 1302 | $j(that).data( 'ignoreLooksInternal', true ); |
1305 | 1303 | $j(that).closest( '.ui-dialog' ).find( 'button:first' ).click(); |
1306 | 1304 | $j(that).data( 'ignoreLooksInternal', false ); |
1307 | 1305 | $j(this).dialog( 'close' ); |
1308 | 1306 | }; |
1309 | 1307 | $j.wikiEditor.modules.dialogs.quickDialog( |
1310 | | - u.getMsg( 'wikieditor-toolbar-tool-link-lookslikeinternal', match[1] ), |
| 1308 | + mediaWiki.msg( 'wikieditor-toolbar-tool-link-lookslikeinternal', match[1] ), |
1311 | 1309 | { buttons: buttons } |
1312 | 1310 | ); |
1313 | 1311 | return; |
— | — | @@ -1346,7 +1344,7 @@ |
1347 | 1345 | open: function() { |
1348 | 1346 | // Cache the articlepath regex |
1349 | 1347 | $j(this).data( 'articlePathRegex', new RegExp( |
1350 | | - '^' + RegExp.escape( wgServer + wgArticlePath ) |
| 1348 | + '^' + $.escapeRE( wgServer + wgArticlePath ) |
1351 | 1349 | .replace( /\\\$1/g, '(.*)' ) + '$' |
1352 | 1350 | ) ); |
1353 | 1351 | // Pre-fill the text fields based on the current selection |
— | — | @@ -1454,7 +1452,7 @@ |
1455 | 1453 | init: function() { |
1456 | 1454 | // Insert translated strings into labels |
1457 | 1455 | $j( this ).find( '[rel]' ).each( function() { |
1458 | | - $j( this ).text( mw.usability.getMsg( $j( this ).attr( 'rel' ) ) ); |
| 1456 | + $j( this ).text( mediaWiki.msg( $j( this ).attr( 'rel' ) ) ); |
1459 | 1457 | } ); |
1460 | 1458 | |
1461 | 1459 | }, |
— | — | @@ -1600,7 +1598,7 @@ |
1601 | 1599 | </div></div>', |
1602 | 1600 | init: function() { |
1603 | 1601 | $j(this).find( '[rel]' ).each( function() { |
1604 | | - $j(this).text( mw.usability.getMsg( $j(this).attr( 'rel' ) ) ); |
| 1602 | + $j(this).text( mediaWiki.msg( $j(this).attr( 'rel' ) ) ); |
1605 | 1603 | }); |
1606 | 1604 | // Set tabindexes on form fields |
1607 | 1605 | $j.wikiEditor.modules.dialogs.fn.setTabindexes( $j(this).find( 'input' ).not( '[tabindex]' ) ); |
— | — | @@ -1661,21 +1659,20 @@ |
1662 | 1660 | var rows = parseInt( rowsVal, 10 ); |
1663 | 1661 | var cols = parseInt( colsVal, 10 ); |
1664 | 1662 | var header = $j( '#wikieditor-toolbar-table-dimensions-header' ).is( ':checked' ) ? 1 : 0; |
1665 | | - var u = mw.usability; |
1666 | 1663 | if ( isNaN( rows ) || isNaN( cols ) || rows != rowsVal || cols != colsVal ) { |
1667 | | - alert( u.getMsg( 'wikieditor-toolbar-tool-table-invalidnumber' ) ); |
| 1664 | + alert( mediaWiki.msg( 'wikieditor-toolbar-tool-table-invalidnumber' ) ); |
1668 | 1665 | return; |
1669 | 1666 | } |
1670 | 1667 | if ( rows + header == 0 || cols == 0 ) { |
1671 | | - alert( u.getMsg( 'wikieditor-toolbar-tool-table-zero' ) ); |
| 1668 | + alert( mediaWiki.msg( 'wikieditor-toolbar-tool-table-zero' ) ); |
1672 | 1669 | return; |
1673 | 1670 | } |
1674 | 1671 | if ( rows * cols > 1000 ) { |
1675 | | - alert( u.getMsg( 'wikieditor-toolbar-tool-table-toomany', 1000 ) ); |
| 1672 | + alert( mediaWiki.msg( 'wikieditor-toolbar-tool-table-toomany', 1000 ) ); |
1676 | 1673 | return; |
1677 | 1674 | } |
1678 | | - var headerText = u.getMsg( 'wikieditor-toolbar-tool-table-example-header' ); |
1679 | | - var normalText = u.getMsg( 'wikieditor-toolbar-tool-table-example' ); |
| 1675 | + var headerText = mediaWiki.msg( 'wikieditor-toolbar-tool-table-example-header' ); |
| 1676 | + var normalText = mediaWiki.msg( 'wikieditor-toolbar-tool-table-example' ); |
1680 | 1677 | var table = ""; |
1681 | 1678 | for ( var r = 0; r < rows + header; r++ ) { |
1682 | 1679 | table += "|-\n"; |
— | — | @@ -1799,9 +1796,8 @@ |
1800 | 1797 | </div>\ |
1801 | 1798 | </fieldset>', |
1802 | 1799 | init: function() { |
1803 | | - var u = mw.usability; |
1804 | 1800 | $j(this).find( '[rel]' ).each( function() { |
1805 | | - $j(this).text( u.getMsg( $j(this).attr( 'rel' ) ) ); |
| 1801 | + $j(this).text( mediaWiki.msg( $j(this).attr( 'rel' ) ) ); |
1806 | 1802 | }); |
1807 | 1803 | // Set tabindexes on form fields |
1808 | 1804 | $j.wikiEditor.modules.dialogs.fn.setTabindexes( $j(this).find( 'input' ).not( '[tabindex]' ) ); |
— | — | @@ -1825,13 +1821,13 @@ |
1826 | 1822 | flags += 'g'; |
1827 | 1823 | } |
1828 | 1824 | if ( !isRegex ) { |
1829 | | - searchStr = RegExp.escape( searchStr ); |
| 1825 | + searchStr = $.escapeRE( searchStr ); |
1830 | 1826 | } |
1831 | 1827 | try { |
1832 | 1828 | var regex = new RegExp( searchStr, flags ); |
1833 | 1829 | } catch( e ) { |
1834 | 1830 | $j( '#wikieditor-toolbar-replace-invalidregex' ) |
1835 | | - .text( u.getMsg( 'wikieditor-toolbar-tool-replace-invalidregex', |
| 1831 | + .text( mediaWiki.msg( 'wikieditor-toolbar-tool-replace-invalidregex', |
1836 | 1832 | e.message ) ) |
1837 | 1833 | .show(); |
1838 | 1834 | return; |
— | — | @@ -1880,7 +1876,7 @@ |
1881 | 1877 | offset = newEnd; |
1882 | 1878 | } |
1883 | 1879 | $j( '#wikieditor-toolbar-replace-success' ) |
1884 | | - .text( u.getMsg( 'wikieditor-toolbar-tool-replace-success', match.length ) ) |
| 1880 | + .text( mediaWiki.msg( 'wikieditor-toolbar-tool-replace-success', match.length ) ) |
1885 | 1881 | .show(); |
1886 | 1882 | $j(this).data( 'offset', 0 ); |
1887 | 1883 | } else { |