Bug 119305
Summary: | Fix a bug that mousedown without mouseup in a frame disturbs click event in another frame | ||
---|---|---|---|
Product: | WebKit | Reporter: | Ryosuke Niwa <rniwa> |
Component: | UI Events | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED FIXED | ||
Severity: | Normal | CC: | ahmad.saleem792, ap, benjamin, enrica, tkent, webkit-bug-importer |
Priority: | P2 | Keywords: | BlinkMergeCandidate, InRadar |
Version: | 528+ (Nightly build) | ||
Hardware: | Unspecified | ||
OS: | Unspecified |
Ryosuke Niwa
Consider merging https://chromium.googlesource.com/chromium/blink/+/01502bee2013aeb0c5b300d4b9bb00ba1e45e596
If a mouse button is clicked but mouseup event for it is not dispatched
(it happens frequently because of context menus) and mousedown in
another frame is default-prevented, 'click' event for the latter mouse
click is not dispatched.
EventHandler::m_capturingMouseEventsNode wrongly continues to hold a node
for the first click, and it prevents hit-testing for the second click. We
should alwyas clear m_capturingMouseEventsNode in mousedown handling code.
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Ahmad Saleem
This is still something can be implemented:
https://github.com/WebKit/WebKit/blob/2ef8bf040a9db8c0af836f5a92916e087e9b9e16/Source/WebCore/page/EventHandler.cpp#L1711
but I don't know alternative names of:
m_eventHandlerWillResetCapturingMouseEventsNode -> can't figure out
m_capturingMouseEventsNode -> could be m_capturingMouseEventsElement
Plus I was not able to test the attached testcase because it requires eventSender, which might be only possible in EWS. Thanks!
Ahmad Saleem
(In reply to Ahmad Saleem from comment #1)
> This is still something can be implemented:
>
> https://github.com/WebKit/WebKit/blob/
> 2ef8bf040a9db8c0af836f5a92916e087e9b9e16/Source/WebCore/page/EventHandler.
> cpp#L1711
>
> but I don't know alternative names of:
>
> m_eventHandlerWillResetCapturingMouseEventsNode -> can't figure out
>
> m_capturingMouseEventsNode -> could be m_capturingMouseEventsElement
>
> Plus I was not able to test the attached testcase because it requires
> eventSender, which might be only possible in EWS. Thanks!
We also have "clearLatchedState", we can call it as well like:
if (xx)
return clearLatchedState;
xx -> m_eventHandlerWillResetCapturingMouseEventsNode (still not clear alternative in Webkit).
EWS
Committed 258055@main (c2dd7ba98908): <https://commits.webkit.org/258055@main>
Reviewed commits have been landed. Closing PR #7811 and removing active labels.
Radar WebKit Bug Importer
<rdar://problem/103484632>