Changeset 7364
- Timestamp:
- 02/16/12 15:07:21 (15 months ago)
- Location:
- CKEditor/trunk
- Files:
-
- 5 edited
-
CHANGES.html (modified) (1 diff)
-
_source/plugins/clipboard/dialogs/paste.js (modified) (1 diff)
-
_source/plugins/dialog/plugin.js (modified) (7 diffs)
-
_source/plugins/dialogui/plugin.js (modified) (1 diff)
-
_source/plugins/tabletools/dialogs/tableCell.js (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
CKEditor/trunk/CHANGES.html
r7351 r7364 47 47 <li><a href="http://dev.ckeditor.com/ticket/8333">#8333</a> : Allow to close the dialogs with Esc key even if there's no Cancel button.</li> 48 48 <li><a href="http://dev.ckeditor.com/ticket/8644">#8644</a> : Missing variable declaration in the dialog plugin.</li> 49 <li><a href="http://dev.ckeditor.com/ticket/8699">#8699</a> : Now focus is moved to clicked button in all browsers and back to colorpicker dialog opener (button) after dialog is closed.</li> 49 50 </ul> 50 51 <h3> -
CKEditor/trunk/_source/plugins/clipboard/dialogs/paste.js
r6825 r7364 46 46 case 9 : 47 47 case CKEDITOR.SHIFT + 9 : 48 this.changeFocus( true);48 this.changeFocus( 1 ); 49 49 processed = 1; 50 50 } -
CKEditor/trunk/_source/plugins/dialog/plugin.js
r7351 r7364 361 361 } 362 362 363 function changeFocus( forward ) 364 { 365 var focusList = me._.focusList, 366 offset = forward ? 1 : -1; 363 function changeFocus( offset ) 364 { 365 var focusList = me._.focusList; 366 offset = offset || 0; 367 367 368 if ( focusList.length < 1 ) 368 369 return; … … 377 378 } 378 379 catch( e ){} 379 380 380 381 var startIndex = ( current + offset + focusList.length ) % focusList.length, 381 382 currentIndex = startIndex; 382 while ( !focusList[ currentIndex ].isFocusable() )383 while ( offset && !focusList[ currentIndex ].isFocusable() ) 383 384 { 384 385 currentIndex = ( currentIndex + offset + focusList.length ) % focusList.length; … … 386 387 break; 387 388 } 389 388 390 focusList[ currentIndex ].focus(); 389 391 … … 421 423 { 422 424 // Change the focus of inputs. 423 changeFocus( !shiftPressed);425 changeFocus( shiftPressed ? -1 : 1 ); 424 426 } 425 427 … … 446 448 this._.tabBarMode = false; 447 449 this._.currentFocusIndex = -1; 448 changeFocus( true);450 changeFocus( 1 ); 449 451 processed = 1; 450 452 } … … 514 516 // Focus the first field in layout order. 515 517 else 516 changeFocus( true);518 changeFocus( 1 ); 517 519 518 520 /* … … 580 582 this._.tabBarMode = false; 581 583 this._.currentFocusIndex = -1; 582 changeFocus( true);584 changeFocus( 1 ); 583 585 } 584 586 evt.data.preventDefault(); -
CKEditor/trunk/_source/plugins/dialogui/plugin.js
r7297 r7364 971 971 /** @ignore */ 972 972 onClick : function( dialog, func ) 973 { 974 this.on( 'click', func ); 973 { 974 this.on( 'click', function() 975 { 976 // Some browsers (Chrome, IE8, IE7 compat mode) don't move 977 // focus to clicked button. Force this. 978 this.getElement().focus(); 979 func.apply( this, arguments ); 980 }); 975 981 } 976 982 }, true ), -
CKEditor/trunk/_source/plugins/tabletools/dialogs/tableCell.js
r6569 r7364 27 27 releaseHandlers( this ); 28 28 callback( this, this._.parentDialog ); 29 this._.parentDialog.changeFocus( true);29 this._.parentDialog.changeFocus(); 30 30 }; 31 31 var onCancel = function()
Note: See TracChangeset
for help on using the changeset viewer.
