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

Side by Side Diff: content/renderer/gpu/render_widget_compositor.cc

Issue 105393003: Always fall back to root scroll layer for otherwise ignored scrolls (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use max scroll offset Created 6 years, 11 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 unified diff | Download patch
« no previous file with comments | « cc/trees/layer_tree_settings.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/gpu/render_widget_compositor.h" 5 #include "content/renderer/gpu/render_widget_compositor.h"
6 6
7 #include <limits> 7 #include <limits>
8 #include <string> 8 #include <string>
9 9
10 #if defined(OS_ANDROID) 10 #if defined(OS_ANDROID)
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after
258 settings.max_partial_texture_updates = 0; 258 settings.max_partial_texture_updates = 0;
259 settings.scrollbar_animator = cc::LayerTreeSettings::LinearFade; 259 settings.scrollbar_animator = cc::LayerTreeSettings::LinearFade;
260 settings.solid_color_scrollbar_color = 260 settings.solid_color_scrollbar_color =
261 cmd->HasSwitch(switches::kHideScrollbars) 261 cmd->HasSwitch(switches::kHideScrollbars)
262 ? SK_ColorTRANSPARENT 262 ? SK_ColorTRANSPARENT
263 : SkColorSetARGB(128, 128, 128, 128); 263 : SkColorSetARGB(128, 128, 128, 128);
264 settings.highp_threshold_min = 2048; 264 settings.highp_threshold_min = 2048;
265 // Android WebView handles root layer flings itself. 265 // Android WebView handles root layer flings itself.
266 settings.ignore_root_layer_flings = 266 settings.ignore_root_layer_flings =
267 widget->UsingSynchronousRendererCompositor(); 267 widget->UsingSynchronousRendererCompositor();
268 settings.always_overscroll = widget->UsingSynchronousRendererCompositor();
269 // RGBA_4444 textures are only enabled for low end devices 268 // RGBA_4444 textures are only enabled for low end devices
270 // and are disabled for Android WebView as it doesn't support the format. 269 // and are disabled for Android WebView as it doesn't support the format.
271 settings.use_rgba_4444_textures = 270 settings.use_rgba_4444_textures =
272 base::android::SysUtils::IsLowEndDevice() && 271 base::android::SysUtils::IsLowEndDevice() &&
273 !widget->UsingSynchronousRendererCompositor() && 272 !widget->UsingSynchronousRendererCompositor() &&
274 !cmd->HasSwitch(cc::switches::kDisable4444Textures); 273 !cmd->HasSwitch(cc::switches::kDisable4444Textures);
275 #elif !defined(OS_MACOSX) 274 #elif !defined(OS_MACOSX)
276 if (cmd->HasSwitch(switches::kEnableOverlayScrollbars)) { 275 if (cmd->HasSwitch(switches::kEnableOverlayScrollbars)) {
277 settings.scrollbar_animator = cc::LayerTreeSettings::Thinning; 276 settings.scrollbar_animator = cc::LayerTreeSettings::Thinning;
278 } 277 }
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after
637 widget_->OnSwapBuffersAborted(); 636 widget_->OnSwapBuffersAborted();
638 } 637 }
639 638
640 void RenderWidgetCompositor::RateLimitSharedMainThreadContext() { 639 void RenderWidgetCompositor::RateLimitSharedMainThreadContext() {
641 cc::ContextProvider* provider = 640 cc::ContextProvider* provider =
642 RenderThreadImpl::current()->SharedMainThreadContextProvider().get(); 641 RenderThreadImpl::current()->SharedMainThreadContextProvider().get();
643 provider->Context3d()->rateLimitOffscreenContextCHROMIUM(); 642 provider->Context3d()->rateLimitOffscreenContextCHROMIUM();
644 } 643 }
645 644
646 } // namespace content 645 } // namespace content
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_settings.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698