Opened 9 years ago

Closed 9 years ago

#17318 closed defect (wontfix)

dijit/Menu does not work with dijit/Editor

Reported by: George Sexton Owned by: bill
Priority: undecided Milestone: tbd
Component: Dijit Version: 1.9.1
Keywords: Cc:
Blocked By: Blocking:


If you use a digit/Menu and specify targetNodeIds that should link it to a defined dijit/Editor, it doesn't work.

I've created a test case page that demonstrates this:

Steps to Reproduce Load the test case page. Right click on the two form elements, and then right click on the digit/Editor text entry area.

Observed Behavior

Right clicking on the two form elements works, but right clicking on the editor does not work.

Expected Behavior

Right clicking on the digit/Editor should activate the context menu.

Other Comments

I've noticed that if you have an invalid targetNodeId in dijit/Menu, it stops parsing of the page. That's not very robust.

I've tested the issue with Firefox 22, Safari, and IE 10. The behavior is the same on all platforms.

Attachments (2)

EditorTestCase.html (1.4 KB) - added by George Sexton 9 years ago.
Test case page that demonstrates the issue.
EditorTestCase_working.html (1.6 KB) - added by bill 9 years ago.
explicitly attaches to iframe

Download all attachments as: .zip

Change History (4)

Changed 9 years ago by George Sexton

Attachment: EditorTestCase.html added

Test case page that demonstrates the issue.

comment:1 Changed 9 years ago by bill

Component: GeneralDijit
Owner: set to bill

OK, thanks for the test case. It's not really feasible to make your test case work as is, but I'll tell you how to workaround the problem. You need to explicitly create the menu on the Editor's iframe. That's complicated because the Editor initializes asynchronously, but the code is basically:

require(["dojo/parser", "dijit/Editor", "dijit/Menu", "dijit/MenuItem", "dojo/domReady!"], function(parser){

I'll attach a modified version of your test case that works.

Changed 9 years ago by bill

Attachment: EditorTestCase_working.html added

explicitly attaches to iframe

comment:2 Changed 9 years ago by bill

Resolution: wontfix
Status: newclosed
Note: See TracTickets for help on using tickets.