Ticket #7175: 7175_2.patch
File 7175_2.patch, 1.9 KB (added by , 13 years ago) |
---|
-
_source/plugins/floatpanel/plugin.js
101 101 block = panel.showBlock( name ); 102 102 103 103 this.allowBlur( false ); 104 isShowing = 1;105 104 106 105 // Record from where the focus is when open panel. 107 106 this._.returnFocus = this._.editor.focusManager.hasFocus ? this._.editor : new CKEDITOR.dom.element( CKEDITOR.document.$.activeElement ); … … 166 165 if ( target.getName && target.getName() != 'iframe' ) 167 166 return; 168 167 169 if ( this.visible && !this._.activeChild && !isShowing)168 if ( this.visible && !this._.activeChild ) 170 169 { 171 170 // Panel close is caused by user's navigating away the focus, e.g. click outside the panel. 172 171 // DO NOT restore focus in this case. … … 302 301 left : left + 'px' 303 302 } ); 304 303 element.setOpacity( 1 ); 305 } , this );306 304 305 // Necessary buffer time for IE to move focus into the iframe when host page is in a modal dialog. (#7175) 306 CKEDITOR.tools.setTimeout( function() { iframe.$.contentWindow.focus(); }, 307 CKEDITOR.env.ie && window.dialogArguments !== undefined ? 100 : 0 ); 308 309 } , this ); 307 310 panel.isLoaded ? panelLoad() : panel.onLoad = panelLoad; 308 311 309 // Set the panel frame focus, so the blur event gets fired.310 CKEDITOR.tools.setTimeout( function()311 {312 iframe.$.contentWindow.focus();313 // We need this get fired manually because of unfired focus() function.314 this.allowBlur( true );315 }, 0, this);316 312 }, CKEDITOR.env.air ? 200 : 0, this); 317 313 this.visible = 1; 318 314 319 315 if ( this.onShow ) 320 316 this.onShow.call( this ); 321 317 322 isShowing = 0;323 318 }, 324 319 325 320 hide : function( returnFocus )