Opened 16 years ago
Closed 16 years ago
#3716 closed Bug (fixed)
Context menu disappears after displaying one submenu
Reported by: | Damian | Owned by: | Frederico Caldeira Knabben |
---|---|---|---|
Priority: | Normal | Milestone: | CKEditor 3.0 |
Component: | General | Version: | |
Keywords: | IBM Confirmed Review+ | Cc: |
Description
Same issue as reported in #3566
Browser: IE7 OS: Vista
Attachments (3)
Change History (17)
comment:1 Changed 16 years ago by
Owner: | set to Martin Kou |
---|---|
Status: | new → assigned |
comment:2 Changed 16 years ago by
Keywords: | Pending added |
---|
comment:3 Changed 16 years ago by
I have tested on today's nightly build with IE7 on Vista. The trick to reproducing this error is to use the Ajax sample.
Follow these steps:
- Open Ajax sample
- Add some text followed by a new table with default settings.
- Check the context menu on the table cells.
3.1 Right click in a cell and hover over until cell properties appears
3.2 Move over to the cell properties sub menu
- At this point the context menu should be visible
- Remove Editor
- Create Editor
- Repeat steps 2-4
The context menu will disappear.
comment:4 Changed 16 years ago by
Keywords: | Confirmed added; Pending removed |
---|
Confirmed the bug on IE and Firefox.
comment:5 Changed 16 years ago by
The bug occurs whenever multiple editors have existed on the same page. A simpler way to reproduce this bug would be:
- Open replacebycode.html in any browser.
- Right click anywhere in the first editor to get a context menu.
- Add a default table in the second editor.
- Right click with the table selected in the second editor, and try to open any submenu.
- The parent context menu disappears.
I've noticed that there's duplicated event registration for the blur and focus DOM events in floatpanel plugin when there're multiple editors. But fixing that alone does fix the issue.
Changed 16 years ago by
Attachment: | 3716.patch added |
---|
comment:7 Changed 16 years ago by
Keywords: | Review? added |
---|
The problem here is that different editor instances would have created separate floatPanel instances, but they share the same iframe DOM nodes. So these creates two problems:
- The focus and blur handlers for the iframes are registered more than once when there're two or more editor instances.
- The "this" reference, or any variable references within the scope of a floatPanel instance, are no longer reliable in the focus/blur handlers.
comment:8 Changed 16 years ago by
Keywords: | Review- added; Review? removed |
---|---|
Summary: | Context menu disappears after displaying one submenu in IE7 on Vista → Context menu disappears after displaying one submenu |
I'm not sure this is a problem related to the fix, but when following the steps defined in comment:3 the first level context menu is not getting closed when clicking in the editing area after showing a second level menu. This happens only on the second time we create an editor instance.
Changed 16 years ago by
Attachment: | 3716_2.patch added |
---|
comment:9 Changed 16 years ago by
Keywords: | Review? added; Review- removed |
---|
The fix did not cause the problem - it's that we're having the same instance variable synchronization problem with onHide and focused.
comment:10 Changed 16 years ago by
Keywords: | Review- added; Review? removed |
---|
This patch is breaking the panel based toolbar elements, like the color selectors:
- Click a color button.
- Click on the editing area to close it. (The button will stay blue).
- Click the button again to open it. (Nothing happens).
comment:11 Changed 16 years ago by
Owner: | changed from Martin Kou to Frederico Caldeira Knabben |
---|---|
Status: | assigned → new |
It looks like we just need a flag there, to avoid executing the hiding code when it's not needed. I have a new patch for it.
Changed 16 years ago by
Attachment: | 3716_3.patch added |
---|
comment:12 Changed 16 years ago by
Keywords: | Review? added; Review- removed |
---|---|
Status: | new → assigned |
comment:13 Changed 16 years ago by
Keywords: | Review+ added; Review? removed |
---|
I've tested today's trunk with IE6/7/8 on both XP and Vista and I haven't been able to reproduce this bug.