Index: trunk/extensions/UsabilityInitiative/UsabilityInitiative.hooks.php |
— | — | @@ -72,7 +72,7 @@ |
73 | 73 | array( 'src' => 'js/plugins/jquery.namespaceSelect.js', 'version' => 1 ), |
74 | 74 | array( 'src' => 'js/plugins/jquery.suggestions.js', 'version' => 7 ), |
75 | 75 | array( 'src' => 'js/plugins/jquery.textSelection.js', 'version' => 27 ), |
76 | | - array( 'src' => 'js/plugins/jquery.wikiEditor.js', 'version' => 109 ), |
| 76 | + array( 'src' => 'js/plugins/jquery.wikiEditor.js', 'version' => 110 ), |
77 | 77 | array( 'src' => 'js/plugins/jquery.wikiEditor.highlight.js', 'version' => 29 ), |
78 | 78 | array( 'src' => 'js/plugins/jquery.wikiEditor.toolbar.js', 'version' => 47 ), |
79 | 79 | array( 'src' => 'js/plugins/jquery.wikiEditor.dialogs.js', 'version' => 12 ), |
— | — | @@ -82,10 +82,10 @@ |
83 | 83 | array( 'src' => 'js/plugins/jquery.wikiEditor.publish.js', 'version' => 2 ), |
84 | 84 | ), |
85 | 85 | 'combined' => array( |
86 | | - array( 'src' => 'js/plugins.combined.js', 'version' => 227 ), |
| 86 | + array( 'src' => 'js/plugins.combined.js', 'version' => 228 ), |
87 | 87 | ), |
88 | 88 | 'minified' => array( |
89 | | - array( 'src' => 'js/plugins.combined.min.js', 'version' => 227 ), |
| 89 | + array( 'src' => 'js/plugins.combined.min.js', 'version' => 228 ), |
90 | 90 | ), |
91 | 91 | ), |
92 | 92 | ); |
Index: trunk/extensions/UsabilityInitiative/js/plugins/jquery.wikiEditor.js |
— | — | @@ -301,14 +301,18 @@ |
302 | 302 | return false; |
303 | 303 | } |
304 | 304 | break; |
| 305 | + // Intercept all tab events to provide consisten behavior across browsers |
| 306 | + // Webkit browsers insert tab characters by default into the iframe rather than changing input focus |
305 | 307 | case 9: |
306 | 308 | var $tabindexList = $j( '[tabindex]:visible' ).sort( function( a, b ) { |
307 | 309 | return a.tabIndex > b.tabIndex ? 1 : -1; |
308 | 310 | } ); |
309 | | - while( ! $tabindexList.eq( 0 ).is( '#' + context.$iframe.attr( 'id' ) ) ) { |
310 | | - $tabindexList = $tabindexList.slice( 1 ); |
| 311 | + for( var i=0; i < $tabindexList.length; i++ ) { |
| 312 | + if( $tabindexList.eq( i ).is( '#' + context.$iframe.attr( 'id' ) ) ) { |
| 313 | + $tabindexList.get( i + 1 ).focus(); |
| 314 | + break; |
| 315 | + } |
311 | 316 | } |
312 | | - $tabindexList.get( 1 ).focus(); |
313 | 317 | return false; |
314 | 318 | break; |
315 | 319 | } |
Index: trunk/extensions/UsabilityInitiative/js/plugins.combined.js |
— | — | @@ -6734,14 +6734,18 @@ |
6735 | 6735 | return false; |
6736 | 6736 | } |
6737 | 6737 | break; |
| 6738 | + // Intercept all tab events to provide consisten behavior across browsers |
| 6739 | + // Webkit browsers insert tab characters by default into the iframe rather than changing input focus |
6738 | 6740 | case 9: |
6739 | 6741 | var $tabindexList = $j( '[tabindex]:visible' ).sort( function( a, b ) { |
6740 | 6742 | return a.tabIndex > b.tabIndex ? 1 : -1; |
6741 | 6743 | } ); |
6742 | | - while( ! $tabindexList.eq( 0 ).is( '#' + context.$iframe.attr( 'id' ) ) ) { |
6743 | | - $tabindexList = $tabindexList.slice( 1 ); |
| 6744 | + for( var i=0; i < $tabindexList.length; i++ ) { |
| 6745 | + if( $tabindexList.eq( i ).is( '#' + context.$iframe.attr( 'id' ) ) ) { |
| 6746 | + $tabindexList.get( i + 1 ).focus(); |
| 6747 | + break; |
| 6748 | + } |
6744 | 6749 | } |
6745 | | - $tabindexList.get( 1 ).focus(); |
6746 | 6750 | return false; |
6747 | 6751 | break; |
6748 | 6752 | } |
Index: trunk/extensions/UsabilityInitiative/js/plugins.combined.min.js |
— | — | @@ -447,8 +447,8 @@ |
448 | 448 | 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--;} |
449 | 449 | 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));} |
450 | 450 | return false;} |
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;} |
| 451 | +break;case 9:var $tabindexList=$j('[tabindex]:visible').sort(function(a,b){return a.tabIndex>b.tabIndex?1:-1;});for(var i=0;i<$tabindexList.length;i++){if($tabindexList.eq(i).is('#'+context.$iframe.attr('id'))){$tabindexList.get(i+1).focus();break;}} |
| 452 | +return false;break;} |
453 | 453 | 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';} |
454 | 454 | switch(event.which){case 8:break;} |
455 | 455 | 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;} |