r82972 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r82971‎ | r82972 | r82973 >
Date:22:38, 28 February 2011
Author:krinkle
Status:deferred (Comments)
Tags:
Comment:
Fix IE-bug. Element creation must have valid syntax, does not accept shortcuts
Modified paths:
  • /trunk/extensions/Translate/js/translate.langstats.js (modified) (history)

Diff [purge]

Index: trunk/extensions/Translate/js/translate.langstats.js
@@ -4,7 +4,7 @@
55 * @created January 3, 2011
66 * @license GPL v2, CC-BY-SA-3.0
77 */
8 -jQuery( document ).ready( function() {
 8+jQuery( document ).ready( function( $ ) {
99
1010 var $translateTable = $( '.mw-sp-translate-table' ),
1111 $metaRows = $( 'tr[data-ismeta=1]', $translateTable );
@@ -22,7 +22,7 @@
2323 if ( $thisChildRows.size() ) {
2424
2525 // Build toggle link
26 - var $toggler = $( '<span class="mw-sp-langstats-toggle mw-sp-langstats-expander">[</span>' ).append( $( '<a href="#" onclick="return false;">' ).text( mw.msg( 'translate-langstats-expand' ) ) ).append( ']' ).click( function() {
 26+ var $toggler = $( '<span class="mw-sp-langstats-toggle mw-sp-langstats-expander">[</span>' ).append( $( '<a href="#" onclick="return false;"></a>' ).text( mw.msg( 'translate-langstats-expand' ) ) ).append( ']' ).click( function() {
2727 var $el = $( this );
2828 // Switch the state and toggle the rows
2929 if ( $el.hasClass( 'mw-sp-langstats-expander' ) ) {
@@ -44,7 +44,7 @@
4545 // Create, bind and append the toggle-all button
4646 var $allChildRows = $( 'tr[data-parentgroups]', $translateTable ),
4747 $allToggles_cache = null,
48 - $toggleAllButton = $( '<span class="mw-sp-langstats-expander">[</span>' ).append( $( '<a href="#" onclick="return false;">' ).text( mw.msg( 'translate-langstats-expandall' ) ) ).append( ']' ).click( function() {
 48+ $toggleAllButton = $( '<span class="mw-sp-langstats-expander">[</span>' ).append( $( '<a href="#" onclick="return false;"></a>' ).text( mw.msg( 'translate-langstats-expandall' ) ) ).append( ']' ).click( function() {
4949 var $el = $( this ),
5050 $allToggles = !!$allToggles_cache ? $allToggles_cache : $( '.mw-sp-langstats-toggle', $translateTable );
5151 // Switch the state and toggle the rows
@@ -72,7 +72,7 @@
7373
7474 // When hovering a row, adjust brightness of the last two custom-colored cells as well
7575 // See also translate.langstats.css for the highlighting for the other normal rows
76 -mediaWiki.loader.using( 'jquery.colorUtil' , function() {
 76+mw.loader.using( 'jquery.colorUtil' , function() {
7777
7878 $( '.mw-sp-translate-table.wikitable tr' ).hover( function() {
7979

Comments

#Comment by Krinkle (talk | contribs)   22:42, 28 February 2011

Fixes (bug 27794) "expand"/"collapse" not displayed on Special:LanguageStats in IE8

Status & tagging log