Ticket #4677: 4677_3.patch
File 4677_3.patch, 2.5 KB (added by , 14 years ago) |
---|
-
_source/core/dom/element.js
739 739 */ 740 740 isVisible : function() 741 741 { 742 return this.$.offsetWidth && ( this.$.style.visibility != 'hidden' ); 742 var isVisible = !!this.$.offsetHeight && this.getComputedStyle( 'visibility' ) != 'hidden', 743 elementWindow, 744 elementWindowFrame; 745 746 // Webkit and Opera report non-zero offsetHeight despite that 747 // element is inside an invisible iframe. (#4542) 748 if ( isVisible && ( CKEDITOR.env.webkit || CKEDITOR.env.opera ) ) 749 { 750 elementWindow = this.getWindow(); 751 752 if ( !elementWindow.equals( CKEDITOR.document.getWindow() ) 753 && ( elementWindowFrame = elementWindow.$.frameElement ) ) 754 isVisible = new CKEDITOR.dom.element( elementWindowFrame ).isVisible(); 755 } 756 757 return isVisible; 743 758 }, 744 759 745 760 /** -
_source/plugins/dialog/plugin.js
464 464 this.focusIndex = index; 465 465 this.isFocusable = function() 466 466 { 467 return true;467 return !( element.getAttribute( 'disabled' ) || !element.isVisible() ) 468 468 }; 469 469 this.focus = function() 470 470 { … … 2460 2460 */ 2461 2461 isVisible : function() 2462 2462 { 2463 var element = this.getInputElement(), 2464 elementWindow = element.getWindow(), 2465 elementFrame, 2466 isVisible = !!element.$.offsetHeight; 2467 2468 // Webkit and Opera report non-zero offsetHeight despite that 2469 // element is inside an invisible iframe. (#4542) 2470 if( isVisible && ( CKEDITOR.env.webkit || CKEDITOR.env.opera ) 2471 && !elementWindow.equals( CKEDITOR.document.getWindow() ) 2472 && ( elementFrame = elementWindow.$.frameElement ) ) 2473 isVisible = !!elementFrame.offsetHeight; 2474 2475 return isVisible; 2463 return this.getInputElement().isVisible(); 2476 2464 }, 2477 2465 2478 2466 /** -
_source/plugins/dialogui/plugin.js
838 838 839 839 isVisible : function() 840 840 { 841 return !!this.getElement().$.firstChild.offsetHeight;841 return this.getElement().getFirst().isVisible(); 842 842 }, 843 843 844 844 isEnabled : function()