Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2976)

Unified Diff: content/renderer/render_view_impl.cc

Issue 314753002: Set up Finch experiment for expanded GPU rasterization trigger (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address asvitkine's comments Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_view_impl.cc
diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc
index 7257b007bca385082e9e507b6c4678334854ab50..87c62c06a7bd34b658cab12ba2c702394d60191e 100644
--- a/content/renderer/render_view_impl.cc
+++ b/content/renderer/render_view_impl.cc
@@ -20,6 +20,7 @@
#include "base/lazy_instance.h"
#include "base/memory/scoped_ptr.h"
#include "base/message_loop/message_loop_proxy.h"
+#include "base/metrics/field_trial.h"
#include "base/metrics/histogram.h"
#include "base/path_service.h"
#include "base/process/kill.h"
@@ -472,6 +473,11 @@ static bool ShouldUseAcceleratedFixedRootBackground(float 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) {
switch (type) {
case blink::WebIconURL::TypeFavicon:
@@ -751,6 +757,8 @@ void RenderViewImpl::Initialize(RenderViewImplParams* params) {
ShouldUseAcceleratedFixedRootBackground(device_scale_factor_));
webview()->settings()->setCompositedScrollingForFramesEnabled(
ShouldUseCompositedScrollingForFrames(device_scale_factor_));
+ webview()->settings()->setUseExpandedHeuristicsForGpuRasterization(
+ ShouldUseExpandedHeuristicsForGpuRasterization());
ApplyWebPreferences(webkit_preferences_, webview());
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698