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

Side by Side Diff: cc/trees/layer_tree_impl.cc

Issue 2421913002: Change Aura overlay scrollbars from solid color to painted scrollbars. (Closed)
Patch Set: Rebase Created 4 years, 2 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_host_impl_unittest.cc ('k') | cc/trees/layer_tree_settings.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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 "cc/trees/layer_tree_impl.h" 5 #include "cc/trees/layer_tree_impl.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 1341 matching lines...) Expand 10 before | Expand all | Expand 10 after
1352 gfx::Size LayerTreeImpl::DrawViewportSize() const { 1352 gfx::Size LayerTreeImpl::DrawViewportSize() const {
1353 return layer_tree_host_impl_->DrawViewportSize(); 1353 return layer_tree_host_impl_->DrawViewportSize();
1354 } 1354 }
1355 1355
1356 const gfx::Rect LayerTreeImpl::ViewportRectForTilePriority() const { 1356 const gfx::Rect LayerTreeImpl::ViewportRectForTilePriority() const {
1357 return layer_tree_host_impl_->ViewportRectForTilePriority(); 1357 return layer_tree_host_impl_->ViewportRectForTilePriority();
1358 } 1358 }
1359 1359
1360 std::unique_ptr<ScrollbarAnimationController> 1360 std::unique_ptr<ScrollbarAnimationController>
1361 LayerTreeImpl::CreateScrollbarAnimationController(int scroll_layer_id) { 1361 LayerTreeImpl::CreateScrollbarAnimationController(int scroll_layer_id) {
1362 DCHECK(settings().scrollbar_fade_delay_ms); 1362 DCHECK(!settings().scrollbar_fade_delay.is_zero());
1363 DCHECK(settings().scrollbar_fade_duration_ms); 1363 DCHECK(!settings().scrollbar_fade_duration.is_zero());
1364 base::TimeDelta delay = 1364 base::TimeDelta delay = settings().scrollbar_fade_delay;
1365 base::TimeDelta::FromMilliseconds(settings().scrollbar_fade_delay_ms); 1365 base::TimeDelta resize_delay = settings().scrollbar_fade_resize_delay;
1366 base::TimeDelta resize_delay = base::TimeDelta::FromMilliseconds( 1366 base::TimeDelta duration = settings().scrollbar_fade_duration;
1367 settings().scrollbar_fade_resize_delay_ms);
1368 base::TimeDelta duration =
1369 base::TimeDelta::FromMilliseconds(settings().scrollbar_fade_duration_ms);
1370 switch (settings().scrollbar_animator) { 1367 switch (settings().scrollbar_animator) {
1371 case LayerTreeSettings::LINEAR_FADE: { 1368 case LayerTreeSettings::LINEAR_FADE: {
1372 return ScrollbarAnimationControllerLinearFade::Create( 1369 return ScrollbarAnimationControllerLinearFade::Create(
1373 scroll_layer_id, layer_tree_host_impl_, delay, resize_delay, 1370 scroll_layer_id, layer_tree_host_impl_, delay, resize_delay,
1374 duration); 1371 duration);
1375 } 1372 }
1376 case LayerTreeSettings::THINNING: { 1373 case LayerTreeSettings::THINNING: {
1377 return ScrollbarAnimationControllerThinning::Create( 1374 return ScrollbarAnimationControllerThinning::Create(
1378 scroll_layer_id, layer_tree_host_impl_, delay, resize_delay, 1375 scroll_layer_id, layer_tree_host_impl_, delay, resize_delay,
1379 duration); 1376 duration);
(...skipping 697 matching lines...) Expand 10 before | Expand all | Expand 10 after
2077 2074
2078 void LayerTreeImpl::ResetAllChangeTracking() { 2075 void LayerTreeImpl::ResetAllChangeTracking() {
2079 layers_that_should_push_properties_.clear(); 2076 layers_that_should_push_properties_.clear();
2080 // Iterate over all layers, including masks. 2077 // Iterate over all layers, including masks.
2081 for (auto& layer : *layers_) 2078 for (auto& layer : *layers_)
2082 layer->ResetChangeTracking(); 2079 layer->ResetChangeTracking();
2083 property_trees_.ResetAllChangeTracking(); 2080 property_trees_.ResetAllChangeTracking();
2084 } 2081 }
2085 2082
2086 } // namespace cc 2083 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host_impl_unittest.cc ('k') | cc/trees/layer_tree_settings.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698