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

Side by Side Diff: blimp/common/compositor/blimp_layer_tree_settings.cc

Issue 1324263003: Blimp: create MessageDispatcher class. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@blimp-protos
Patch Set: Addressed nyquist's feedback Created 5 years, 3 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "blimp/common/compositor/blimp_layer_tree_settings.h" 5 #include "blimp/common/compositor/blimp_layer_tree_settings.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "base/strings/string_number_conversions.h" 10 #include "base/strings/string_number_conversions.h"
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
232 settings->renderer_settings.should_clear_root_render_pass = true; 232 settings->renderer_settings.should_clear_root_render_pass = true;
233 233
234 // TODO(danakj): Only do this on low end devices. 234 // TODO(danakj): Only do this on low end devices.
235 settings->create_low_res_tiling = true; 235 settings->create_low_res_tiling = true;
236 236
237 // TODO(dtrainor): Investigate whether or not we want to use an external 237 // TODO(dtrainor): Investigate whether or not we want to use an external
238 // source here. 238 // source here.
239 // settings->use_external_begin_frame_source = true; 239 // settings->use_external_begin_frame_source = true;
240 240
241 #elif !defined(OS_MACOSX) 241 #elif !defined(OS_MACOSX)
242 if (ui::IsOverlayScrollbarEnabled()) { 242 NOTIMPLEMENTED() << "Unresolved dependency TODO for native_theme.";
nyquist 2015/09/10 03:47:33 This should be unnecessary now.
Kevin M 2015/09/10 18:11:17 Done.
243 settings->scrollbar_animator = cc::LayerTreeSettings::THINNING; 243 // TODO(dtrainor): Add blimp to ui/native_theme DEPS and re-enable
244 settings->solid_color_scrollbar_color = SkColorSetARGB(128, 128, 128, 128); 244 // this section.
245 } else { 245
246 settings->scrollbar_animator = cc::LayerTreeSettings::LINEAR_FADE; 246 // if (ui::IsOverlayScrollbarEnabled()) {
247 settings->solid_color_scrollbar_color = SkColorSetARGB(128, 128, 128, 128); 247 // settings->scrollbar_animator = cc::LayerTreeSettings::THINNING;
248 } 248 // settings->solid_color_scrollbar_color =
249 settings->scrollbar_fade_delay_ms = 500; 249 // SkColorSetARGB(128, 128, 128, 128);
250 settings->scrollbar_fade_resize_delay_ms = 500; 250 // } else {
251 settings->scrollbar_fade_duration_ms = 300; 251 // settings->scrollbar_animator = cc::LayerTreeSettings::LINEAR_FADE;
252 // settings->solid_color_scrollbar_color =
253 // SkColorSetARGB(128, 128, 128, 128);
254 // }
255 // settings->scrollbar_fade_delay_ms = 500;
256 // settings->scrollbar_fade_resize_delay_ms = 500;
257 // settings->scrollbar_fade_duration_ms = 300;
252 258
253 // When pinching in, only show the pinch-viewport overlay scrollbars if the 259 // When pinching in, only show the pinch-viewport overlay scrollbars if the
254 // page scale is at least some threshold away from the minimum. i.e. don't 260 // page scale is at least some threshold away from the minimum. i.e. don't
255 // show the pinch scrollbars when at minimum scale. 261 // show the pinch scrollbars when at minimum scale.
256 settings->scrollbar_show_scale_threshold = 1.05f; 262 //
263 // TODO(dtrainor): Re-enable or delete this line entirely.
264 // (LayerTreeSettings::scrollbar_show_scale_threshold does not exist.)
265 // settings->scrollbar_show_scale_threshold = 1.05f;
257 #endif 266 #endif
258 267
259 if (cmd.HasSwitch(switches::kEnableLowResTiling)) 268 if (cmd.HasSwitch(switches::kEnableLowResTiling))
260 settings->create_low_res_tiling = true; 269 settings->create_low_res_tiling = true;
261 if (cmd.HasSwitch(switches::kDisableLowResTiling)) 270 if (cmd.HasSwitch(switches::kDisableLowResTiling))
262 settings->create_low_res_tiling = false; 271 settings->create_low_res_tiling = false;
263 if (cmd.HasSwitch(cc::switches::kEnableBeginFrameScheduling)) 272 if (cmd.HasSwitch(cc::switches::kEnableBeginFrameScheduling))
264 settings->use_external_begin_frame_source = true; 273 settings->use_external_begin_frame_source = true;
265 } 274 }
266 275
267 } // namespace blimp 276 } // namespace blimp
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698