Index: _whatsnew.html
===================================================================
--- _whatsnew.html (revision 1688)
+++ _whatsnew.html (working copy)
@@ -58,6 +58,9 @@
mode.
[#1934] Fixed
JavaScript errors when calling Selection.EnsureSelection() in dialogs.
+ [#1838] Fixed the
+ issue where context menus sometimes don't disappear after selecting an option.
+
Version 2.6 Beta 1
Index: editor/_source/classes/fckpanel.js
===================================================================
--- editor/_source/classes/fckpanel.js (revision 1686)
+++ editor/_source/classes/fckpanel.js (working copy)
@@ -270,6 +270,13 @@
top : y + 'px'
} ) ;
+ // Move the focus to the IFRAME so we catch the "onblur".
+ this._IFrame.width = this._IFrame.height = 2 ;
+ this._IFrame.contentWindow.focus() ;
+ this._IsOpened = true ;
+
+ // Fix for #1514: The color panels are sometimes too small when they're opened.
+ // A delayed resize is needed to get the correct sizes.
var me = this ;
var resizeFunc = function()
{
@@ -277,12 +284,9 @@
var iHeight = eMainNode.offsetHeight ;
me._IFrame.width = iWidth ;
me._IFrame.height = iHeight ;
-
- // Move the focus to the IFRAME so we catch the "onblur".
- me._IFrame.contentWindow.focus() ;
- me._IsOpened = true ;
+ me._resizeTimer = null ;
}
- setTimeout( resizeFunc, 1 ) ;
+ this._resizeTimer = setTimeout( resizeFunc, 1 ) ;
FCK.ToolbarSet.CurrentInstance.GetInstanceObject( 'FCKPanel' )._OpenedPanel = this ;
}
@@ -308,6 +312,11 @@
this._IFrame.width = this._IFrame.height = 0 ;
this._IsOpened = false ;
+ if ( this._resizeTimer )
+ {
+ clearTimeout( this._resizeTimer ) ;
+ this._resizeTimer = null ;
+ }
if ( this.ParentPanel )
this.ParentPanel.Unlock() ;