r89613 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r89612‎ | r89613 | r89614 >
Date:21:43, 6 June 2011
Author:krinkle
Status:resolved
Tags:
Comment:
Redo r89605 in a better way.
Modified paths:
  • /trunk/phase3/resources/jquery/jquery.tabIndex.js (modified) (history)

Diff [purge]

Index: trunk/phase3/resources/jquery/jquery.tabIndex.js
@@ -11,13 +11,15 @@
1212 var minTabIndex = null;
1313 $(this).find( '[tabindex]' ).each( function( i ) {
1414 var tabIndex = parseInt( $(this).attr( 'tabindex' ), 10 );
15 - if ( i === 0 ) {
16 - minTabIndex = tabIndex;
1715 // In IE6/IE7 the above jQuery selector returns all elements,
1816 // becuase it has a default value for tabIndex in IE6/IE7 of 0
1917 // (rather than null/undefined). Therefore check "> 0" as well
20 - } else if ( tabIndex > 0 && tabIndex < minTabIndex ) {
21 - minTabIndex = tabIndex;
 18+ if ( tabIndex > 0 ) {
 19+ if ( i === 0 ) {
 20+ minTabIndex = tabIndex;
 21+ } else if ( tabIndex < minTabIndex ) {
 22+ minTabIndex = tabIndex;
 23+ }
2224 }
2325 } );
2426 return minTabIndex;

Follow-up revisions

RevisionCommit summaryAuthorDate
r89614Alright, IE7 is fixed by r89613. IE6 stays problematic, for some reason it co...krinkle21:51, 6 June 2011

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r89605Fix bug that brakes the 'jquery.tabIndex > firstTabIndex' test in IE6/IE7 (Th...krinkle20:57, 6 June 2011

Status & tagging log