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

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

Issue 230223006: Move nonscrollable axis gloweffect suppression to renderer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: clean up and modified as per review comments Created 6 years, 8 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 | « content/browser/renderer_host/render_widget_host_view_android.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 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 !cmd->HasSwitch(switches::kDisableGpuVsync); 92 !cmd->HasSwitch(switches::kDisableGpuVsync);
93 settings.begin_impl_frame_scheduling_enabled = 93 settings.begin_impl_frame_scheduling_enabled =
94 cmd->HasSwitch(switches::kEnableBeginFrameScheduling); 94 cmd->HasSwitch(switches::kEnableBeginFrameScheduling);
95 settings.main_frame_before_activation_enabled = 95 settings.main_frame_before_activation_enabled =
96 cmd->HasSwitch(cc::switches::kEnableMainFrameBeforeActivation) && 96 cmd->HasSwitch(cc::switches::kEnableMainFrameBeforeActivation) &&
97 !cmd->HasSwitch(cc::switches::kDisableMainFrameBeforeActivation); 97 !cmd->HasSwitch(cc::switches::kDisableMainFrameBeforeActivation);
98 settings.main_frame_before_draw_enabled = 98 settings.main_frame_before_draw_enabled =
99 !cmd->HasSwitch(cc::switches::kDisableMainFrameBeforeDraw); 99 !cmd->HasSwitch(cc::switches::kDisableMainFrameBeforeDraw);
100 settings.using_synchronous_renderer_compositor = 100 settings.using_synchronous_renderer_compositor =
101 widget->UsingSynchronousRendererCompositor(); 101 widget->UsingSynchronousRendererCompositor();
102 settings.report_overscroll_only_for_scrollable_axes =
103 !widget->UsingSynchronousRendererCompositor();
102 settings.accelerated_animation_enabled = 104 settings.accelerated_animation_enabled =
103 !cmd->HasSwitch(cc::switches::kDisableThreadedAnimation); 105 !cmd->HasSwitch(cc::switches::kDisableThreadedAnimation);
104 settings.touch_hit_testing = 106 settings.touch_hit_testing =
105 !cmd->HasSwitch(cc::switches::kDisableCompositorTouchHitTesting) && 107 !cmd->HasSwitch(cc::switches::kDisableCompositorTouchHitTesting) &&
106 !cmd->HasSwitch(switches::kEnableBleedingEdgeRenderingFastPaths); 108 !cmd->HasSwitch(switches::kEnableBleedingEdgeRenderingFastPaths);
107 109
108 int default_tile_width = settings.default_tile_size.width(); 110 int default_tile_width = settings.default_tile_size.width();
109 if (cmd->HasSwitch(switches::kDefaultTileWidth)) { 111 if (cmd->HasSwitch(switches::kDefaultTileWidth)) {
110 GetSwitchValueAsInt(*cmd, switches::kDefaultTileWidth, 1, 112 GetSwitchValueAsInt(*cmd, switches::kDefaultTileWidth, 1,
111 std::numeric_limits<int>::max(), &default_tile_width); 113 std::numeric_limits<int>::max(), &default_tile_width);
(...skipping 537 matching lines...) Expand 10 before | Expand all | Expand 10 after
649 widget_->OnSwapBuffersAborted(); 651 widget_->OnSwapBuffersAborted();
650 } 652 }
651 653
652 void RenderWidgetCompositor::RateLimitSharedMainThreadContext() { 654 void RenderWidgetCompositor::RateLimitSharedMainThreadContext() {
653 cc::ContextProvider* provider = 655 cc::ContextProvider* provider =
654 RenderThreadImpl::current()->SharedMainThreadContextProvider().get(); 656 RenderThreadImpl::current()->SharedMainThreadContextProvider().get();
655 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM(); 657 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM();
656 } 658 }
657 659
658 } // namespace content 660 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/renderer_host/render_widget_host_view_android.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698