Index: trunk/extensions/UploadWizard/resources/mw.UploadWizardDeed.js |
— | — | @@ -106,42 +106,36 @@ |
107 | 107 | |
108 | 108 | _this.$form = $j( '<form/>' ); |
109 | 109 | |
| 110 | + var $authorInput2 = $j( '<input>' ).attr( { name: "author2", type: "text" } ).addClass( 'mwe-upwiz-sign' ); |
110 | 111 | var $standardDiv = $j( '<div />' ).append( |
111 | 112 | $j( '<label for="author2" generated="true" class="mwe-validator-error" style="display:block;"/>' ), |
112 | | - $j( '<p>' ) |
113 | | - .html( gM( 'mwe-upwiz-source-ownwork-assert', |
114 | | - uploadCount, |
115 | | - '<span class="mwe-standard-author-input"></span>' ) |
116 | | - ), |
117 | | - $j( '<p class="mwe-small-print" />' ).append( gM( 'mwe-upwiz-source-ownwork-assert-note' ) ) |
| 113 | + $j( '<p>' ).msg( 'mwe-upwiz-source-ownwork-assert', |
| 114 | + uploadCount, |
| 115 | + $authorInput2 ), |
| 116 | + $j( '<p class="mwe-small-print" />' ).msg( 'mwe-upwiz-source-ownwork-assert-note' ) |
118 | 117 | ); |
119 | | - $standardDiv.find( '.mwe-standard-author-input' ).append( $j( '<input name="author2" type="text" class="mwe-upwiz-sign" />' ) ); |
120 | 118 | |
121 | 119 | var $customDiv = $j('<div/>').append( |
122 | 120 | $j( '<label for="author" generated="true" class="mwe-validator-error" style="display:block;"/>' ), |
123 | | - $j( '<p>' ) |
124 | | - .html( gM( 'mwe-upwiz-source-ownwork-assert-custom', |
125 | | - uploadCount, |
126 | | - '<span class="mwe-custom-author-input"></span>' ) ), |
| 121 | + $j( '<p>' ).msg( 'mwe-upwiz-source-ownwork-assert-custom', |
| 122 | + uploadCount, |
| 123 | + _this.authorInput ), |
127 | 124 | licenseInputDiv |
128 | 125 | ); |
129 | | - // have to add the author input this way -- gM() will flatten it to a string and we'll lose it as a dom object |
130 | | - $customDiv.find( '.mwe-custom-author-input' ).append( _this.authorInput ); |
131 | 126 | |
132 | | - |
133 | 127 | var $crossfader = $j( '<div>' ).append( $standardDiv, $customDiv ); |
134 | 128 | var $toggler = $j( '<p class="mwe-more-options" style="text-align: right" />' ) |
135 | 129 | .append( $j( '<a />' ) |
136 | | - .append( gM( 'mwe-upwiz-license-show-all' ) ) |
| 130 | + .msg( 'mwe-upwiz-license-show-all' ) |
137 | 131 | .click( function() { |
138 | 132 | _this.formValidator.resetForm(); |
139 | 133 | if ( $crossfader.data( 'crossfadeDisplay' ) === $customDiv ) { |
140 | 134 | _this.licenseInput.setDefaultValues(); |
141 | 135 | $crossfader.morphCrossfade( $standardDiv ); |
142 | | - $j( this ).html( gM( 'mwe-upwiz-license-show-all' ) ); |
| 136 | + $j( this ).msg( 'mwe-upwiz-license-show-all' ); |
143 | 137 | } else { |
144 | 138 | $crossfader.morphCrossfade( $customDiv ); |
145 | | - $j( this ).html( gM( 'mwe-upwiz-license-show-recommended' ) ); |
| 139 | + $j( this ).msg( 'mwe-upwiz-license-show-recommended' ); |
146 | 140 | } |
147 | 141 | } ) ); |
148 | 142 | |
— | — | @@ -237,7 +231,7 @@ |
238 | 232 | var $formFields = $j( '<div class="mwe-upwiz-deed-form-internal"/>' ); |
239 | 233 | |
240 | 234 | if ( uploadCount > 1 ) { |
241 | | - $formFields.append( $j( '<div />' ).append( gM( 'mwe-upwiz-source-thirdparty-custom-multiple-intro' ) ) ); |
| 235 | + $formFields.append( $j( '<div />' ).msg( 'mwe-upwiz-source-thirdparty-custom-multiple-intro' ) ); |
242 | 236 | } |
243 | 237 | |
244 | 238 | $formFields.append ( |
Index: trunk/extensions/UploadWizard/resources/mw.UploadWizardUtil.js |
— | — | @@ -24,13 +24,11 @@ |
25 | 25 | if ( open ) { |
26 | 26 | moreDiv.show(); // maskSafeShow(); |
27 | 27 | /* when open, show control to close */ |
28 | | - $toggleLink.html( gM( 'mwe-upwiz-fewer-options' ) ); |
29 | | - $toggleLink.addClass( "mwe-upwiz-toggler-open" ); |
| 28 | + $toggleLink.msg( 'mwe-upwiz-fewer-options' ).addClass( "mwe-upwiz-toggler-open" ); |
30 | 29 | } else { |
31 | 30 | moreDiv.hide(); // maskSafeHide(); |
32 | 31 | /* when closed, show control to open */ |
33 | | - $toggleLink.html( gM( 'mwe-upwiz-more-options' ) ); |
34 | | - $toggleLink.removeClass( "mwe-upwiz-toggler-open" ); |
| 32 | + $toggleLink.msg( 'mwe-upwiz-more-options' ).removeClass( "mwe-upwiz-toggler-open" ); |
35 | 33 | } |
36 | 34 | }; |
37 | 35 | |
Index: trunk/extensions/UploadWizard/resources/mw.UploadWizard.js |
— | — | @@ -510,12 +510,12 @@ |
511 | 511 | |
512 | 512 | $j( '<div>' ) |
513 | 513 | .insertBefore( _this.deedChooser.$selector.find( '.mwe-upwiz-deed-ownwork' ) ) |
514 | | - .html( gM( 'mwe-upwiz-deeds-macro-prompt', _this.uploads.length ) ); |
| 514 | + .msg( 'mwe-upwiz-deeds-macro-prompt', _this.uploads.length ); |
515 | 515 | |
516 | 516 | if ( _this.uploads.length > 1 ) { |
517 | 517 | $j( '<div style="margin-top: 1em">' ) |
518 | 518 | .insertBefore( _this.deedChooser.$selector.find( '.mwe-upwiz-deed-custom' ) ) |
519 | | - .html( gM( 'mwe-upwiz-deeds-custom-prompt' ) ); |
| 519 | + .msg( 'mwe-upwiz-deeds-custom-prompt' ); |
520 | 520 | } |
521 | 521 | |
522 | 522 | _this.moveToStep( 'deeds' ); |
— | — | @@ -862,7 +862,7 @@ |
863 | 863 | $j( '#mwe-upwiz-upload-ctrl-container' ).show(); |
864 | 864 | |
865 | 865 | // changes the "click here to add files" to "add another file" |
866 | | - $j( '#mwe-upwiz-add-file span' ).html( gM( 'mwe-upwiz-add-file-n' ) ); |
| 866 | + $j( '#mwe-upwiz-add-file span' ).msg( 'mwe-upwiz-add-file-n' ); |
867 | 867 | $j( '#mwe-upwiz-add-file-container' ).removeClass('mwe-upwiz-add-files-0'); |
868 | 868 | $j( '#mwe-upwiz-add-file-container' ).addClass('mwe-upwiz-add-files-n'); |
869 | 869 | |
— | — | @@ -889,7 +889,7 @@ |
890 | 890 | $j( '#mwe-upwiz-stepdiv-file .mwe-upwiz-buttons' ).hide(); |
891 | 891 | |
892 | 892 | // change "add another file" into "click here to add a file" |
893 | | - $j( '#mwe-upwiz-add-file' ).html( gM( 'mwe-upwiz-add-file-0' ) ); |
| 893 | + $j( '#mwe-upwiz-add-file' ).msg( 'mwe-upwiz-add-file-0' ); |
894 | 894 | $j( '#mwe-upwiz-add-file-container' ).addClass('mwe-upwiz-add-files-0'); |
895 | 895 | $j( '#mwe-upwiz-add-file-container' ).removeClass('mwe-upwiz-add-files-n'); |
896 | 896 | } |
— | — | @@ -977,9 +977,9 @@ |
978 | 978 | var _this = this; |
979 | 979 | |
980 | 980 | $j( '#mwe-upwiz-thanks' ) |
981 | | - .append( $j( '<h3 style="text-align: center;">' ).append( gM( 'mwe-upwiz-thanks-intro' ) ), |
| 981 | + .append( $j( '<h3 style="text-align: center;">' ).msg( 'mwe-upwiz-thanks-intro' ), |
982 | 982 | $j( '<p style="margin-bottom: 2em; text-align: center;">' ) |
983 | | - .append( gM( 'mwe-upwiz-thanks-explain', _this.uploads.length ) ) ); |
| 983 | + .msg( 'mwe-upwiz-thanks-explain', _this.uploads.length ) ); |
984 | 984 | |
985 | 985 | $j.each( _this.uploads, function(i, upload) { |
986 | 986 | var thanksDiv = $j( '<div class="mwe-upwiz-thanks ui-helper-clearfix" />' ); |