#16867 closed defect (fixed)
Menu: listener leak on mouseenter listener
Reported by: | bill | Owned by: | bill |
---|---|---|---|
Priority: | undecided | Milestone: | 1.7.5 |
Component: | Dijit | Version: | 1.4.0 |
Keywords: | Cc: | Douglas Hays | |
Blocked By: | Blocking: |
Description
Every time a drop down menu is opened, _MenuBase runs this code:
popup.own(on(popup.domNode, "mouseenter", lang.hitch(self, "_onPopupHover"))); // cleaned up when the popped-up widget is destroyed on close
The big problem is that new listeners keep getting created, but the old ones are never destroyed. The comment is incorrect; the drop down is not destroyed when it's closed. The code should probably be using on.once(), and the listener should also be removed when the drop down is closed, even if it never got a mouseenter event. Error is from [20098], refs #6773.
The other problem is that "mouseenter" is not a valid event name, except on IE. It should be dojo/mouse::enter, or actually plain "mouseover" would work too. This is a mistake from [30834], refs #16784 .
Change History (5)
comment:1 Changed 8 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:4 Changed 8 years ago by
Cc: | Douglas Hays added |
---|---|
Milestone: | tbd → 1.7.5 |
Version: | 1.8.3 → 1.4.0 |
Note: See
TracTickets for help on using
tickets.
In [30888]: