RESOLVED FIXED 197004
[Pointer Events WPT] Unskip imported/w3c/web-platform-tests/pointerevents/pointerevent_lostpointercapture_for_disconnected_node.html
https://bugs.webkit.org/show_bug.cgi?id=197004
Summary [Pointer Events WPT] Unskip imported/w3c/web-platform-tests/pointerevents/poi...
Antoine Quint
Reported 2019-04-17 07:02:16 PDT
The test at imported/w3c/web-platform-tests/pointerevents/pointerevent_lostpointercapture_for_disconnected_node.html is timing out and is skipped currently.
Attachments
Patch (11.74 KB, patch)
2019-04-18 02:26 PDT, Antoine Quint
koivisto: review+
Antoine Quint
Comment 1 2019-04-17 07:07:26 PDT
We don't release pointer capture when a node that has pointer capture is disconnected.
Antoine Quint
Comment 2 2019-04-18 02:26:49 PDT
Antti Koivisto
Comment 3 2019-04-18 06:11:56 PDT
Comment on attachment 367722 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=367722&action=review > Source/WebCore/page/PointerCaptureController.cpp:133 > + for (auto& keyAndValue : m_activePointerIdsToCapturingData) { I suppose this map is mostly empty/has very few items? > Source/WebCore/page/PointerCaptureController.cpp:147 > + return; > + } I feel for loops read better if the bail out case is a branch, not the body of the loop.
Antoine Quint
Comment 4 2019-04-18 06:24:49 PDT
(In reply to Antti Koivisto from comment #3) > Comment on attachment 367722 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=367722&action=review > > > Source/WebCore/page/PointerCaptureController.cpp:133 > > + for (auto& keyAndValue : m_activePointerIdsToCapturingData) { > > I suppose this map is mostly empty/has very few items? Yes. On macOS, it will be empty except if the page has explicitly requested pointer capture for the single active pointer. So the map would have at most one item in it on macOS. On iOS, pointer capture is implicit, so that map will have as many items as there are active touches, which most likely will be 1 or 2. > > Source/WebCore/page/PointerCaptureController.cpp:147 > > + return; > > + } > > I feel for loops read better if the bail out case is a branch, not the body > of the loop. Cool, I'll change it.
Antoine Quint
Comment 5 2019-04-18 06:31:24 PDT
Radar WebKit Bug Importer
Comment 6 2019-04-18 06:32:22 PDT
Note You need to log in before you can comment on or make changes to this bug.