Ticket #3593: 3593_2.patch
File 3593_2.patch, 1.9 KB (added by , 15 years ago) |
---|
-
_source/plugins/wysiwygarea/plugin.js
349 349 // Disable and re-enable the body to avoid IE from 350 350 // taking the editing focus at startup. (#141 / #523) 351 351 body.disabled = true; 352 body.contentEditable = true;353 352 body.removeAttribute( 'disabled' ); 354 353 } 355 else 356 // Avoid opening design mode in a frame window thread, 357 // which will cause host page scrolling.(#4397) 358 setTimeout( function(){ 359 domDocument.$.designMode = 'on'; 360 }, 0 ); 354 // Firefox require design-mode been turned on to make 355 // the cursor blinking when editing frame window gain 356 // keyboard focus. 357 else if ( CKEDITOR.env.gecko ) 358 domDocument.designMode = 'on'; 361 359 360 // Standard way to enable rich-text editing on the 361 // whole page beside Firefox2. 362 body.contentEditable = true; 363 362 364 // IE, Opera and Safari may not support it and throw 363 365 // errors. 364 366 try { domDocument.execCommand( 'enableObjectResizing', false, !editor.config.disableObjectResizing ) ; } catch(e) {} … … 422 424 focusTarget.on( 'blur', function() 423 425 { 424 426 editor.focusManager.blur(); 427 if( CKEDITOR.env.gecko ) 428 editor.document.$.designMode = 'on'; 429 425 430 }); 426 431 427 432 focusTarget.on( 'focus', function() 428 433 { 429 434 editor.focusManager.focus(); 430 }); 435 436 if( CKEDITOR.env.gecko ) 437 setTimeout( function() 438 { 439 editor.document.$.designMode = 'off'; 440 } ); 441 }); 431 442 432 443 var keystrokeHandler = editor.keystrokeHandler; 433 444 if ( keystrokeHandler )