X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=_source%2Fplugins%2Fmaximize%2Fplugin.js;h=9f1804371ec95c4d93e3aa6e53c48aeac6f0352f;hb=055b6b0792ce7dc53d47af606b367c04b927c2ab;hp=a5a06fc1989f4b374e7904744036262758b7c429;hpb=8665a7c6c60586526e32e8941fe2896739b6ebfb;p=ckeditor.git diff --git a/_source/plugins/maximize/plugin.js b/_source/plugins/maximize/plugin.js index a5a06fc..9f18043 100644 --- a/_source/plugins/maximize/plugin.js +++ b/_source/plugins/maximize/plugin.js @@ -80,6 +80,21 @@ For licensing, see LICENSE.html or http://ckeditor.com/license function refreshCursor( editor ) { + // Refresh all editor instances on the page (#5724). + var all = CKEDITOR.instances; + for ( var i in all ) + { + var one = all[ i ]; + if ( one.mode == 'wysiwyg' ) + { + var body = one.document.getBody(); + // Refresh 'contentEditable' otherwise + // DOM lifting breaks design mode. (#5560) + body.setAttribute( 'contentEditable', false ); + body.setAttribute( 'contentEditable', true ); + } + } + if ( editor.focusManager.hasFocus ) { editor.toolbox.focus(); @@ -211,6 +226,10 @@ For licensing, see LICENSE.html or http://ckeditor.com/license } ); shim = createIframeShim( container ); // IE6 select element penetration when maximized. (#4459) + + // Add cke_maximized class before resize handle since that will change things sizes (#5580) + container.addClass( 'cke_maximized' ); + resizeHandler(); // Still not top left? Fix it. (Bug #174) @@ -224,8 +243,6 @@ For licensing, see LICENSE.html or http://ckeditor.com/license // Fixing positioning editor chrome in Firefox break design mode. (#5149) CKEDITOR.env.gecko && refreshCursor( editor ); - // Add cke_maximized class. - container.addClass( 'cke_maximized' ); } else if ( this.state == CKEDITOR.TRISTATE_ON ) // Restore from fullscreen if the state is on. {