Index: trunk/phase3/resources/mediawiki.util/mediawiki.util.test.js |
— | — | @@ -90,7 +90,7 @@ |
91 | 91 | 'function (string)'); |
92 | 92 | mw.test.addTest('mw.util.rawurlencode( \'Test: A&B/Here\' )', |
93 | 93 | 'Test%3A%20A%26B%2FHere (string)'); |
94 | | - mw.test.addTest('typeof mw.util.wfGetlink', |
| 94 | + mw.test.addTest('typeof mw.util.wikiGetlink', |
95 | 95 | 'function (string)'); |
96 | 96 | mw.test.addTest('typeof mw.util.getParamValue', |
97 | 97 | 'function (string)'); |
Index: trunk/phase3/resources/mediawiki.util/mediawiki.util.js |
— | — | @@ -74,8 +74,8 @@ |
75 | 75 | * Checks if the current browser matches |
76 | 76 | * |
77 | 77 | * @example mw.util.isBrowser( 'safari' ); |
78 | | - * @param String str name of a browser (case insensitive). Check jquery.client.js for possible values |
79 | | - * @return Boolean true of the browsername matches the clients browser |
| 78 | + * @param String str name of a browser (case insensitive). Check jquery.client.js for possible values |
| 79 | + * @return Boolean true of the browsername matches the clients browser |
80 | 80 | */ |
81 | 81 | 'isBrowser' : function( str ) { |
82 | 82 | str = (str + '').toLowerCase(); |
— | — | @@ -86,8 +86,8 @@ |
87 | 87 | * Checks if the current layout matches |
88 | 88 | * |
89 | 89 | * @example mw.util.isLayout( 'webkit' ); |
90 | | - * @param String str name of a layout engine (case insensitive). Check jquery.client.js for possible values |
91 | | - * @return Boolean true of the layout engine matches the clients browser |
| 90 | + * @param String str name of a layout engine (case insensitive). Check jquery.client.js for possible values |
| 91 | + * @return Boolean true of the layout engine matches the clients browser |
92 | 92 | */ |
93 | 93 | 'isLayout' : function( str ) { |
94 | 94 | str = (str + '').toLowerCase(); |
— | — | @@ -98,8 +98,8 @@ |
99 | 99 | * Checks if the current layout matches |
100 | 100 | * |
101 | 101 | * @example mw.util.isPlatform( 'mac' ); |
102 | | - * @param String str name of a platform (case insensitive). Check jquery.client.js for possible values |
103 | | - * @return Boolean true of the platform matches the clients platform |
| 102 | + * @param String str name of a platform (case insensitive). Check jquery.client.js for possible values |
| 103 | + * @return Boolean true of the platform matches the clients platform |
104 | 104 | */ |
105 | 105 | 'isPlatform' : function( str ) { |
106 | 106 | str = (str + '').toLowerCase(); |
— | — | @@ -110,8 +110,8 @@ |
111 | 111 | * Checks if the current browser version matches |
112 | 112 | * |
113 | 113 | * @example mw.util.isBrowserVersion( '5' ); |
114 | | - * @param String str version number without decimals |
115 | | - * @return Boolean true of the version number matches the clients browser |
| 114 | + * @param String str version number without decimals |
| 115 | + * @return Boolean true of the version number matches the clients browser |
116 | 116 | */ |
117 | 117 | 'isBrowserVersion' : function( str ) { |
118 | 118 | return this.clientProfile.versionBase === str; |
— | — | @@ -135,24 +135,24 @@ |
136 | 136 | * |
137 | 137 | * @param String str string to be encoded |
138 | 138 | */ |
139 | | - 'wfUrlencode' : function( str ) { |
| 139 | + 'wikiUrlencode' : function( str ) { |
140 | 140 | return this.rawurlencode( str ).replace( /%20/g, '_' ).replace( /%3A/g, ':' ).replace( /%2F/g, '/' ); |
141 | 141 | }, |
142 | 142 | |
143 | 143 | /** |
144 | 144 | * Get the full url to a pagename |
145 | 145 | * |
146 | | - * @param String str pagename to link to |
| 146 | + * @param String str pagename to link to |
147 | 147 | */ |
148 | | - 'wfGetlink' : function( str ) { |
149 | | - return wgServer + wgArticlePath.replace( '$1', this.wfUrlencode( str ) ); |
| 148 | + 'wikiGetlink' : function( str ) { |
| 149 | + return wgServer + wgArticlePath.replace( '$1', this.wikiUrlencode( str ) ); |
150 | 150 | }, |
151 | 151 | |
152 | 152 | /** |
153 | 153 | * Check is a variable is empty. Support for strings, booleans, arrays and objects. |
154 | 154 | * String "0" is considered empty. String containing only whitespace (ie. " ") is considered not empty. |
155 | 155 | * |
156 | | - * @param Mixed v the variable to check for empty ness |
| 156 | + * @param Mixed v the variable to check for empty ness |
157 | 157 | */ |
158 | 158 | 'isEmpty' : function( v ) { |
159 | 159 | var key; |
— | — | @@ -246,7 +246,7 @@ |
247 | 247 | return; |
248 | 248 | } |
249 | 249 | |
250 | | - $nodes.each(function ( i ) { |
| 250 | + $nodes.each( function ( i ) { |
251 | 251 | var tip = $(this).attr( 'title' ); |
252 | 252 | if ( !!tip && mw.util.tooltipAccessKeyRegexp.exec( tip ) ) { |
253 | 253 | tip = tip.replace( mw.util.tooltipAccessKeyRegexp, '[' + mw.util.tooltipAccessKeyPrefix + "$5]" ); |