Commit f29efe6b authored by ajuma@chromium.org's avatar ajuma@chromium.org

Set up field trial for expanded GPU rasterization trigger

This expands the GPU rasterization trigger for a field trial.

This depends on Blink CL http://crrev.com/309593007

BUG=380454

Review URL: https://codereview.chromium.org/314753002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@275769 0039d316-1c4b-4281-b951-d872f2087c98
parent bdd3d42c
...@@ -20,6 +20,7 @@ ...@@ -20,6 +20,7 @@
#include "base/lazy_instance.h" #include "base/lazy_instance.h"
#include "base/memory/scoped_ptr.h" #include "base/memory/scoped_ptr.h"
#include "base/message_loop/message_loop_proxy.h" #include "base/message_loop/message_loop_proxy.h"
#include "base/metrics/field_trial.h"
#include "base/metrics/histogram.h" #include "base/metrics/histogram.h"
#include "base/path_service.h" #include "base/path_service.h"
#include "base/process/kill.h" #include "base/process/kill.h"
...@@ -471,6 +472,11 @@ static bool ShouldUseAcceleratedFixedRootBackground(float device_scale_factor) { ...@@ -471,6 +472,11 @@ static bool ShouldUseAcceleratedFixedRootBackground(float device_scale_factor) {
return DeviceScaleEnsuresTextQuality(device_scale_factor); return DeviceScaleEnsuresTextQuality(device_scale_factor);
} }
static bool ShouldUseExpandedHeuristicsForGpuRasterization() {
return base::FieldTrialList::FindFullName(
"GpuRasterizationExpandedContentWhitelist") == "Enabled";
}
static FaviconURL::IconType ToFaviconType(blink::WebIconURL::Type type) { static FaviconURL::IconType ToFaviconType(blink::WebIconURL::Type type) {
switch (type) { switch (type) {
case blink::WebIconURL::TypeFavicon: case blink::WebIconURL::TypeFavicon:
...@@ -749,6 +755,8 @@ void RenderViewImpl::Initialize(RenderViewImplParams* params) { ...@@ -749,6 +755,8 @@ void RenderViewImpl::Initialize(RenderViewImplParams* params) {
ShouldUseAcceleratedFixedRootBackground(device_scale_factor_)); ShouldUseAcceleratedFixedRootBackground(device_scale_factor_));
webview()->settings()->setCompositedScrollingForFramesEnabled( webview()->settings()->setCompositedScrollingForFramesEnabled(
ShouldUseCompositedScrollingForFrames(device_scale_factor_)); ShouldUseCompositedScrollingForFrames(device_scale_factor_));
webview()->settings()->setUseExpandedHeuristicsForGpuRasterization(
ShouldUseExpandedHeuristicsForGpuRasterization());
ApplyWebPreferences(webkit_preferences_, webview()); ApplyWebPreferences(webkit_preferences_, webview());
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment