Bug 52740

Summary: When a node is moved between documents, EventHandler should be purged of any mention of it
Product: WebKit Reporter: Dimitri Glazkov (Google) <dglazkov>
Component: DOMAssignee: Nobody <webkit-unassigned>
Status: NEW ---    
Severity: Normal CC: ap, darin
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: OS X 10.5   

Description Dimitri Glazkov (Google) 2011-01-19 13:55:16 PST
This came up in bug 52464: after setCapturingMouseEventsNode is set and the node is moved to a different document, bizarre things happen, like events firing into the node from another document. I suspect the same things would happen with mouseUnderMouse/lastMouseUnderMouse, dragTarget, and mousePressNode.

Even though this doesn't appear to be a security issue, we should fix this wierdness.
Comment 1 Darin Adler 2011-01-19 14:06:56 PST
There may be a way to do this at some other level then moving between documents and cover more potential problems. For example, I’m not sure the event handler should continue tracking a node if it’s not rendered any more or not in the document tree any more.

On the other hand, doing this at some other level could be risky, so maybe we should stick to doing it at the “move between documents” level.