Ticket #5559: 5559_3.patch
File 5559_3.patch, 2.7 KB (added by , 14 years ago) |
---|
-
_source/plugins/wysiwygarea/plugin.js
276 276 iframe, 277 277 isLoadingData, 278 278 isPendingFocus, 279 isFrameLoading, 279 280 frameLoaded, 280 281 fireMode; 281 282 … … 289 290 if ( iframe ) 290 291 iframe.remove(); 291 292 292 frameLoaded = 0;293 293 294 294 var setDataFn = !CKEDITOR.env.gecko && CKEDITOR.tools.addFunction( function( doc ) 295 295 { … … 304 304 // call document.open(). 305 305 ( isCustomDomain ? ( 'document.domain="' + document.domain + '";' ) : '' ) + 306 306 307 ( ( 'parent.CKEDITOR.tools.callFunction(' + setDataFn + ',document);' ) ) +308 309 307 'document.close();'; 310 308 311 309 iframe = CKEDITOR.dom.element.createFromHtml( '<iframe' + 312 310 ' style="width:100%;height:100%"' + 313 311 ' frameBorder="0"' + 314 312 ' title="' + frameLabel + '"' + 315 // With FF, the 'src' attribute should be left empty to 313 // With IE, the custom domain has to be taken care at first, 314 // for other browers, the 'src' attribute should be left empty to 316 315 // trigger iframe's 'load' event. 317 ' src="' + ( CKEDITOR.env. gecko ? '' : 'javascript:void(function(){' + encodeURIComponent( srcScript ) + '}())' ) + '"' +316 ' src="' + ( CKEDITOR.env.ie ? 'javascript:void(function(){' + encodeURIComponent( srcScript ) + '}())' : '' ) + '"' + 318 317 ' tabIndex="' + editor.tabIndex + '"' + 319 318 ' allowTransparency="true"' + 320 319 '></iframe>' ); 321 320 322 321 // With FF, it's better to load the data on iframe.load. (#3894,#4058) 323 CKEDITOR.env.gecko &&iframe.on( 'load', function( ev )322 iframe.on( 'load', function( ev ) 324 323 { 324 frameLoaded = 0; 325 325 ev.removeListener(); 326 326 327 327 var doc = iframe.getFrameDocument().$; … … 345 345 // Editing area bootstrap code. 346 346 var contentDomReady = function( domWindow ) 347 347 { 348 if ( frameLoaded )348 if ( frameLoaded !== 0 ) 349 349 return; 350 350 frameLoaded = 1; 351 351 -
_source/core/dom/document.js
198 198 */ 199 199 getDocumentElement : function() 200 200 { 201 var documentElement = new CKEDITOR.dom.element( this.$.documentElement ); 202 203 return ( 204 this.getDocumentElement = function() 205 { 206 return documentElement; 207 })(); 201 return new CKEDITOR.dom.element( this.$.documentElement ); 208 202 }, 209 203 210 204 /**