[WebGL2] Allow enabling WebGL2 with a runtime flag
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 5 Apr 2016 11:22:17 +0000 (11:22 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 5 Apr 2016 11:22:17 +0000 (11:22 +0000)
commitec62b4d704acf99140ff4eac6bf28423bfa04421
treeae55989b3235d9e7ff25eb5ef49fcb8e2290a498
parent65a3a3b3961c85358abff470860b934cf74399c8
[WebGL2] Allow enabling WebGL2 with a runtime flag
https://bugs.webkit.org/show_bug.cgi?id=156166
<rdar://problem/25526929>

Source/WebCore:

Added new runtime flags for WebGL2.

Patch by Antoine Quint <graouts@apple.com> on 2016-04-05
Reviewed by Dean Jackson.

* bindings/generic/RuntimeEnabledFeatures.h:
(WebCore::RuntimeEnabledFeatures::setWebGL2Enabled):
(WebCore::RuntimeEnabledFeatures::webGL2Enabled):

Source/WebKit/mac:

Set the WebGL2 runtime flag based on preferences, disabled by default.

Patch by Antoine Quint <graouts@apple.com> on 2016-04-05
Reviewed by Dean Jackson.

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

Source/WebKit2:

Set the WebGL2 runtime flag based on preferences, disabled by default.

Patch by Antoine Quint <graouts@apple.com> on 2016-04-05
Reviewed by Dean Jackson.

* Shared/WebPreferencesDefinitions.h:
* UIProcess/API/C/WKPreferences.cpp:
(WKPreferencesSetWebGL2Enabled):
(WKPreferencesGetWebGL2Enabled):
* UIProcess/API/C/WKPreferencesRefPrivate.h:
* WebProcess/InjectedBundle/InjectedBundle.cpp:
(WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::updatePreferences):

Source/WTF:

Removed the manual overrides of ENABLE_WEBGL2.

Patch by Antoine Quint <graouts@apple.com> on 2016-04-05
Reviewed by Dean Jackson.

* wtf/FeatureDefines.h:

Tools:

Always enable WebGL2 during testing.

Patch by Antoine Quint <graouts@apple.com> on 2016-04-05
Reviewed by Dean Jackson.

* DumpRenderTree/mac/DumpRenderTree.mm:
(resetWebPreferencesToConsistentValues):
* WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
(WTR::InjectedBundle::beginTesting):
* WebKitTestRunner/InjectedBundle/TestRunner.cpp:
(WTR::TestRunner::setWebGL2Enabled):
* WebKitTestRunner/InjectedBundle/TestRunner.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@199055 268f45cc-cd09-0410-ab3c-d52691b4dbfc
20 files changed:
Source/WTF/ChangeLog
Source/WTF/wtf/FeatureDefines.h
Source/WebCore/ChangeLog
Source/WebCore/bindings/generic/RuntimeEnabledFeatures.h
Source/WebKit/mac/ChangeLog
Source/WebKit/mac/WebView/WebPreferenceKeysPrivate.h
Source/WebKit/mac/WebView/WebPreferences.mm
Source/WebKit/mac/WebView/WebPreferencesPrivate.h
Source/WebKit/mac/WebView/WebView.mm
Source/WebKit2/ChangeLog
Source/WebKit2/Shared/WebPreferencesDefinitions.h
Source/WebKit2/UIProcess/API/C/WKPreferences.cpp
Source/WebKit2/UIProcess/API/C/WKPreferencesRefPrivate.h
Source/WebKit2/WebProcess/InjectedBundle/InjectedBundle.cpp
Source/WebKit2/WebProcess/WebPage/WebPage.cpp
Tools/ChangeLog
Tools/DumpRenderTree/mac/DumpRenderTree.mm
Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp
Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp
Tools/WebKitTestRunner/InjectedBundle/TestRunner.h