[ContentChangeObserver] Add a setting to be able to turn content change observation...
authorzalan@apple.com <zalan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 8 Mar 2019 00:36:42 +0000 (00:36 +0000)
committerzalan@apple.com <zalan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 8 Mar 2019 00:36:42 +0000 (00:36 +0000)
commitba377c98a2da06802ccf4d09ec05c6511dbbd794
treee4371230ecfa951a5ba67d08804b5ca261b8ea15
parentf662e3545d548532aa4d2a1942debd1124ac0df4
[ContentChangeObserver] Add a setting to be able to turn content change observation on/off
https://bugs.webkit.org/show_bug.cgi?id=195353
<rdar://problem/48626394>

Reviewed by Simon Fraser.

Source/WebCore:

Move content observation tests to a dedicated directory.

Tests: fast/events/touch/ios/content-observation/click-instead-of-hover-simple.html
       fast/events/touch/ios/content-observation/hover-when-style-change-is-async.html
       fast/events/touch/ios/content-observation/stuck-with-hover-state.html
       fast/events/touch/ios/content-observation/style-recalc-schedule-and-force-relalc.html
       fast/events/touch/ios/content-observation/visibility-change-happens-at-the-second-timer.html

* page/Settings.yaml:
* page/ios/ContentChangeObserver.cpp:
(WebCore::ContentChangeObserver::didInstallDOMTimer):
(WebCore::ContentChangeObserver::isNotifyContentChangeAllowed const):
* page/ios/ContentChangeObserver.h:
(WebCore::ContentChangeObserver::isNotifyContentChangeAllowed const): Deleted.
* testing/InternalSettings.cpp:
(WebCore::InternalSettings::resetToConsistentState):

Source/WebKit:

* Shared/WebPreferences.yaml:
* UIProcess/API/C/WKPreferences.cpp:
(WKPreferencesSetContentChangeObserverEnabled):
(WKPreferencesGetContentChangeObserverEnabled):
* UIProcess/API/C/WKPreferencesRefPrivate.h:
* UIProcess/API/Cocoa/WKPreferences.mm:
(-[WKPreferences _contentChangeObserverEnabled]):
(-[WKPreferences _setContentChangeObserverEnabled:]):
* UIProcess/API/Cocoa/WKPreferencesPrivate.h:
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::handleSyntheticClick):

Source/WebKitLegacy/mac:

* WebView/WebPreferenceKeysPrivate.h:
* WebView/WebPreferences.mm:
(+[WebPreferences initialize]):
(-[WebPreferences contentChangeObserverEnabled]):
(-[WebPreferences setContentChangeObserverEnabled:]):
* WebView/WebPreferencesPrivate.h:
* WebView/WebView.mm:
(-[WebView _preferencesChanged:]):

Tools:

* WebKitTestRunner/ios/TestControllerIOS.mm:
(WTR::TestController::platformResetPreferencesToConsistentValues):

LayoutTests:

* fast/events/touch/ios/content-observation/click-instead-of-hover-simple-expected.txt: Renamed from LayoutTests/fast/events/touch/ios/click-instead-of-hover-simple-expected.txt.
* fast/events/touch/ios/content-observation/click-instead-of-hover-simple.html: Renamed from LayoutTests/fast/events/touch/ios/click-instead-of-hover-simple.html.
* fast/events/touch/ios/content-observation/hover-when-style-change-is-async-expected.txt: Renamed from LayoutTests/fast/events/touch/ios/hover-when-style-change-is-async-expected.txt.
* fast/events/touch/ios/content-observation/hover-when-style-change-is-async.html: Renamed from LayoutTests/fast/events/touch/ios/hover-when-style-change-is-async.html.
* fast/events/touch/ios/content-observation/stuck-with-hover-state-expected.txt: Renamed from LayoutTests/fast/events/touch/ios/stuck-with-hover-state-expected.txt.
* fast/events/touch/ios/content-observation/stuck-with-hover-state.html: Renamed from LayoutTests/fast/events/touch/ios/stuck-with-hover-state.html.
* fast/events/touch/ios/content-observation/style-recalc-schedule-and-force-relalc-expected.txt: Renamed from LayoutTests/fast/events/touch/ios/style-recalc-schedule-and-force-relalc-expected.txt.
* fast/events/touch/ios/content-observation/style-recalc-schedule-and-force-relalc.html: Renamed from LayoutTests/fast/events/touch/ios/style-recalc-schedule-and-force-relalc.html.
* fast/events/touch/ios/content-observation/visibility-change-happens-at-the-second-timer-expected.txt: Renamed from LayoutTests/fast/events/touch/ios/visibility-change-happens-at-the-second-timer-expected.txt.
* fast/events/touch/ios/content-observation/visibility-change-happens-at-the-second-timer.html: Renamed from LayoutTests/fast/events/touch/ios/visibility-change-happens-at-the-second-timer.html.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@242621 268f45cc-cd09-0410-ab3c-d52691b4dbfc
31 files changed:
LayoutTests/ChangeLog
LayoutTests/fast/events/touch/ios/content-observation/click-instead-of-hover-simple-expected.txt [moved from LayoutTests/fast/events/touch/ios/click-instead-of-hover-simple-expected.txt with 100% similarity]
LayoutTests/fast/events/touch/ios/content-observation/click-instead-of-hover-simple.html [moved from LayoutTests/fast/events/touch/ios/click-instead-of-hover-simple.html with 86% similarity]
LayoutTests/fast/events/touch/ios/content-observation/hover-when-style-change-is-async-expected.txt [moved from LayoutTests/fast/events/touch/ios/hover-when-style-change-is-async-expected.txt with 100% similarity]
LayoutTests/fast/events/touch/ios/content-observation/hover-when-style-change-is-async.html [moved from LayoutTests/fast/events/touch/ios/hover-when-style-change-is-async.html with 90% similarity]
LayoutTests/fast/events/touch/ios/content-observation/stuck-with-hover-state-expected.txt [moved from LayoutTests/fast/events/touch/ios/stuck-with-hover-state-expected.txt with 100% similarity]
LayoutTests/fast/events/touch/ios/content-observation/stuck-with-hover-state.html [moved from LayoutTests/fast/events/touch/ios/stuck-with-hover-state.html with 85% similarity]
LayoutTests/fast/events/touch/ios/content-observation/style-recalc-schedule-and-force-relalc-expected.txt [moved from LayoutTests/fast/events/touch/ios/style-recalc-schedule-and-force-relalc-expected.txt with 100% similarity]
LayoutTests/fast/events/touch/ios/content-observation/style-recalc-schedule-and-force-relalc.html [moved from LayoutTests/fast/events/touch/ios/style-recalc-schedule-and-force-relalc.html with 90% similarity]
LayoutTests/fast/events/touch/ios/content-observation/visibility-change-happens-at-the-second-timer-expected.txt [moved from LayoutTests/fast/events/touch/ios/visibility-change-happens-at-the-second-timer-expected.txt with 100% similarity]
LayoutTests/fast/events/touch/ios/content-observation/visibility-change-happens-at-the-second-timer.html [moved from LayoutTests/fast/events/touch/ios/visibility-change-happens-at-the-second-timer.html with 91% similarity]
Source/WebCore/ChangeLog
Source/WebCore/page/Settings.yaml
Source/WebCore/page/SettingsBase.cpp
Source/WebCore/page/SettingsBase.h
Source/WebCore/page/ios/ContentChangeObserver.cpp
Source/WebCore/page/ios/ContentChangeObserver.h
Source/WebKit/ChangeLog
Source/WebKit/Shared/WebPreferences.yaml
Source/WebKit/UIProcess/API/C/WKPreferences.cpp
Source/WebKit/UIProcess/API/C/WKPreferencesRefPrivate.h
Source/WebKit/UIProcess/API/Cocoa/WKPreferences.mm
Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h
Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm
Source/WebKitLegacy/mac/ChangeLog
Source/WebKitLegacy/mac/WebView/WebPreferenceKeysPrivate.h
Source/WebKitLegacy/mac/WebView/WebPreferences.mm
Source/WebKitLegacy/mac/WebView/WebPreferencesPrivate.h
Source/WebKitLegacy/mac/WebView/WebView.mm
Tools/ChangeLog
Tools/WebKitTestRunner/ios/TestControllerIOS.mm