r62139 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r62138‎ | r62139 | r62140 >
Date:21:56, 8 February 2010
Author:adam
Status:ok
Tags:
Comment:
Tabindex fix for safari and chrome
Modified paths:
  • /trunk/extensions/UsabilityInitiative/UsabilityInitiative.hooks.php (modified) (history)
  • /trunk/extensions/UsabilityInitiative/js/plugins.combined.js (modified) (history)
  • /trunk/extensions/UsabilityInitiative/js/plugins.combined.min.js (modified) (history)
  • /trunk/extensions/UsabilityInitiative/js/plugins/jquery.wikiEditor.js (modified) (history)

Diff [purge]

Index: trunk/extensions/UsabilityInitiative/UsabilityInitiative.hooks.php
@@ -72,7 +72,7 @@
7373 array( 'src' => 'js/plugins/jquery.namespaceSelect.js', 'version' => 1 ),
7474 array( 'src' => 'js/plugins/jquery.suggestions.js', 'version' => 7 ),
7575 array( 'src' => 'js/plugins/jquery.textSelection.js', 'version' => 27 ),
76 - array( 'src' => 'js/plugins/jquery.wikiEditor.js', 'version' => 108 ),
 76+ array( 'src' => 'js/plugins/jquery.wikiEditor.js', 'version' => 109 ),
7777 array( 'src' => 'js/plugins/jquery.wikiEditor.highlight.js', 'version' => 29 ),
7878 array( 'src' => 'js/plugins/jquery.wikiEditor.toolbar.js', 'version' => 47 ),
7979 array( 'src' => 'js/plugins/jquery.wikiEditor.dialogs.js', 'version' => 12 ),
@@ -82,10 +82,10 @@
8383 array( 'src' => 'js/plugins/jquery.wikiEditor.publish.js', 'version' => 2 ),
8484 ),
8585 'combined' => array(
86 - array( 'src' => 'js/plugins.combined.js', 'version' => 226 ),
 86+ array( 'src' => 'js/plugins.combined.js', 'version' => 227 ),
8787 ),
8888 'minified' => array(
89 - array( 'src' => 'js/plugins.combined.min.js', 'version' => 226 ),
 89+ array( 'src' => 'js/plugins.combined.min.js', 'version' => 227 ),
9090 ),
9191 ),
9292 );
Index: trunk/extensions/UsabilityInitiative/js/plugins/jquery.wikiEditor.js
@@ -301,6 +301,16 @@
302302 return false;
303303 }
304304 break;
 305+ case 9:
 306+ var $tabindexList = $j( '[tabindex]:visible' ).sort( function( a, b ) {
 307+ return a.tabIndex > b.tabIndex ? 1 : -1;
 308+ } );
 309+ while( ! $tabindexList.eq( 0 ).is( '#' + context.$iframe.attr( 'id' ) ) ) {
 310+ $tabindexList = $tabindexList.slice( 1 );
 311+ }
 312+ $tabindexList.get( 1 ).focus();
 313+ return false;
 314+ break;
305315 }
306316 return true;
307317 },
Index: trunk/extensions/UsabilityInitiative/js/plugins.combined.js
@@ -6734,6 +6734,16 @@
67356735 return false;
67366736 }
67376737 break;
 6738+ case 9:
 6739+ var $tabindexList = $j( '[tabindex]:visible' ).sort( function( a, b ) {
 6740+ return a.tabIndex > b.tabIndex ? 1 : -1;
 6741+ } );
 6742+ while( ! $tabindexList.eq( 0 ).is( '#' + context.$iframe.attr( 'id' ) ) ) {
 6743+ $tabindexList = $tabindexList.slice( 1 );
 6744+ }
 6745+ $tabindexList.get( 1 ).focus();
 6746+ return false;
 6747+ break;
67386748 }
67396749 return true;
67406750 },
Index: trunk/extensions/UsabilityInitiative/js/plugins.combined.min.js
@@ -447,7 +447,8 @@
448448 if('fn'in $.wikiEditor.modules[module]&&'create'in $.wikiEditor.modules[module].fn){context.modules[module]={};$.wikiEditor.modules[module].fn.create(context,modules[module]);}}}}};context.evt={'keydown':function(event){switch(event.which){case 90:if((event.ctrlKey||event.metaKey)&&context.history.length){if(event.shiftKey){context.historyPosition++;}else{context.historyPosition--;}
449449 if(context.history.length+context.historyPosition>=0&&context.historyPosition<0){context.$content.html(context.history[context.history.length+context.historyPosition].html);}else{context.historyPosition=Math.max(-context.history.length,Math.min(context.historyPosition,-1));}
450450 return false;}
451 -break;}
 451+break;case 9:var $tabindexList=$j('[tabindex]:visible').sort(function(a,b){return a.tabIndex>b.tabIndex?1:-1;});while(!$tabindexList.eq(0).is('#'+context.$iframe.attr('id'))){$tabindexList=$tabindexList.slice(1);}
 452+$tabindexList.get(1).focus();return false;break;}
452453 return true;},'change':function(event){event.data.scope='division';var newHTML=context.$content.html();if(context.oldHTML!=newHTML){context.fn.purgeOffsets();context.oldHTML=newHTML;event.data.scope='realchange';}
453454 switch(event.which){case 8:break;}
454455 return true;},'delayedChange':function(event){event.data.scope='division';var newHTML=context.$content.html();if(context.oldDelayedHTML!=newHTML){context.fn.purgeOffsets();context.oldDelayedHTML=newHTML;event.data.scope='realchange';if(newHTML!==context.history[context.history.length+context.historyPosition].html){context.historyPosition=-1;}

Follow-up revisions

RevisionCommit summaryAuthorDate
r62142Follow up to r62139. Adding a comment and moving from a while, to a for loopadam22:20, 8 February 2010
r62184wmf-deployment: Merge r62139, r62142 and r62145 from trunk (UsabilityInitiati...catrope16:50, 9 February 2010

Status & tagging log