#9531 closed bug (fixed)
Tooltip: memory leak - not unbinding remove event
Reported by: | mdownes | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | 1.11.0 |
Component: | ui.tooltip | Version: | 1.10.3 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
Hi, There seems to be a memory leak in the tooltip where the remove event never gets unbound. Please see the jsfiddle test below for a demonstration. Basically , after hovering over the textbox more and more remove events get bound added and none get unbound. I found this in version 1.9.2 but the test below uses the latest version and it is still present.
Kind Regards,
Maurice
Change History (7)
comment:1 Changed 9 years ago by
Status: | new → open |
---|---|
Summary: | Tooltip memory leak - not unbinding remove event → Tooltip: memory leak - not unbinding remove event |
comment:2 follow-up: 4 Changed 9 years ago by
Fork of the initial jsFiddle w/ the patch from #8740 http://jsfiddle.net/robotdan/v99hx/
Assuming I'm picking up the patched jquery.ui.tooltip.js
it looks like the issue still exists.
comment:3 Changed 9 years ago by
The code block referenced above in comment 1 was added as a result of #8646 under commit https://github.com/jquery/jquery-ui/commit/3b2d1e7736be99671af70aa3b775d67b917517e5.
Some additional investigation should be done to see if the remove
handler can always be removed or if some additional logic is required to resolve this issue as well as preserve the fix for #8846.
comment:4 Changed 9 years ago by
Replying to robotdan:
Fork of the initial jsFiddle w/ the patch from #8740 http://jsfiddle.net/robotdan/v99hx/
Assuming I'm picking up the patched
jquery.ui.tooltip.js
it looks like the issue still exists.
You are bringing in the script file appropriately, so it looks like that fix doesn't address this issue.
comment:6 Changed 9 years ago by
Resolution: | → fixed |
---|---|
Status: | open → closed |
Tooltip: Only bind remove handler for delegated tooltips
The remove handler was being added for every tooltip, but only removed for delegated tooltips. The default destroy behavior already handles non-delegated tooltips, so the handler should only be added for delegated tooltips.
Fixes #9531 Closes gh-1156
Changeset: a8ff77360b78b7eabcffd97b8b11c2d1f150ed4e
comment:7 Changed 9 years ago by
Milestone: | none → 1.11.0 |
---|
Confirmed. A remove handler is bound everytime to tooltip is opened but is only removed for delegated targets:
This might be addressed by the text for #8740.