Opened 14 years ago

Closed 14 years ago

#5567 closed defect (worksforme)

_openMyself function in dijit.Menu should use evt.srcElement instead of for IE

Reported by: guest Owned by:
Priority: high Milestone:
Component: Dijit Version: 1.0
Keywords: Cc:
Blocked By: Blocking:

Description (last modified by bill)

dijit.Menu._openMyself contains code like the following:

		if(dojo.isSafari || this._contextMenuWithMouse){
			// otherwise open near
			var coords = dojo.coords(, true);
			x = coords.x + 10;
			y = coords.y + 10;
			popup: this,
			x: x,
			y: y,
			onExecute: closeAndRestoreFocus,
			onCancel: closeAndRestoreFocus,
			orient: this.isLeftToRight() ? 'L' : 'R'

Unfortunately, does not work on IE and you get an error. If you add an additional check like this it works fine and the popup appears:

                else if (dojo.IE) {
			// otherwise open near
			var coords = dojo.coords(e.srcElement, true);
			x = coords.x + 10;
			y = coords.y + 10;

This code is covered under ATG's CCLA you have on file.

Change History (2)

comment:1 Changed 14 years ago by bill

Description: modified (diff)

I just tried on IE6 and it's working fine for me. What problem are you seeing? Note that dojo does event normalization so that branching like this in client code (like dijit) shouldn't be necessary.

comment:2 Changed 14 years ago by bill

Resolution: worksforme
Status: newclosed

Closing since no response. It's working for me.

Note: See TracTickets for help on using tickets.