[Pointer Events] Check that capturing data managed by the PointerCaptureController...
authorgraouts@webkit.org <graouts@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 28 May 2019 12:33:11 +0000 (12:33 +0000)
committergraouts@webkit.org <graouts@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 28 May 2019 12:33:11 +0000 (12:33 +0000)
commit18c3b10396799cc39558e5aba5c04d4fefbf942b
treeddf32846de6047e96cfbf54d813e8b9c9f5f33f3
parent0ea4a71ccf0e3e12ffd2ae376683e60bbf4c9ed5
[Pointer Events] Check that capturing data managed by the PointerCaptureController gets cleared upon navigation
https://bugs.webkit.org/show_bug.cgi?id=198191

Reviewed by Dean Jackson.

When the document of the page's main frame changes, make sure we clear all of the data accumulated for the previous document.
I don't think this particular change is testable as none of the data contained in the PointerIdToCapturingDataMap maintained by
the PointerCaptureController contains any data that could be inspected by the page due to other fixes landed to fix wkb.ug/198129,
but I've checked that removing those fixes and using this patch correctly fixes that bug.

* page/Page.cpp:
(WebCore::Page::didChangeMainDocument):
* page/PointerCaptureController.cpp:
(WebCore::PointerCaptureController::PointerCaptureController):
(WebCore::PointerCaptureController::reset):
* page/PointerCaptureController.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@245809 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/page/Page.cpp
Source/WebCore/page/PointerCaptureController.cpp
Source/WebCore/page/PointerCaptureController.h