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

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

Issue 2816923002: change overlay scrollbar hover show to hover fade in (Closed)
Patch Set: Created 3 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
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 1467 matching lines...) Expand 10 before | Expand all | Expand 10 after
1478 base::TimeDelta fade_out_duration = settings().scrollbar_fade_out_duration; 1478 base::TimeDelta fade_out_duration = settings().scrollbar_fade_out_duration;
1479 switch (settings().scrollbar_animator) { 1479 switch (settings().scrollbar_animator) {
1480 case LayerTreeSettings::ANDROID_OVERLAY: { 1480 case LayerTreeSettings::ANDROID_OVERLAY: {
1481 return ScrollbarAnimationController:: 1481 return ScrollbarAnimationController::
1482 CreateScrollbarAnimationControllerAndroid( 1482 CreateScrollbarAnimationControllerAndroid(
1483 scroll_layer_id, layer_tree_host_impl_, fade_out_delay, 1483 scroll_layer_id, layer_tree_host_impl_, fade_out_delay,
1484 fade_out_resize_delay, fade_out_duration); 1484 fade_out_resize_delay, fade_out_duration);
1485 } 1485 }
1486 case LayerTreeSettings::AURA_OVERLAY: { 1486 case LayerTreeSettings::AURA_OVERLAY: {
1487 DCHECK(!settings().scrollbar_show_delay.is_zero()); 1487 DCHECK(!settings().scrollbar_show_delay.is_zero());
1488 DCHECK(!settings().scrollbar_fade_in_duration.is_zero());
1488 base::TimeDelta show_delay = settings().scrollbar_show_delay; 1489 base::TimeDelta show_delay = settings().scrollbar_show_delay;
1490 base::TimeDelta fade_in_duration = settings().scrollbar_fade_in_duration;
1489 base::TimeDelta thinning_duration = 1491 base::TimeDelta thinning_duration =
1490 settings().scrollbar_thinning_duration; 1492 settings().scrollbar_thinning_duration;
1491 return ScrollbarAnimationController:: 1493 return ScrollbarAnimationController::
1492 CreateScrollbarAnimationControllerAuraOverlay( 1494 CreateScrollbarAnimationControllerAuraOverlay(
1493 scroll_layer_id, layer_tree_host_impl_, show_delay, 1495 scroll_layer_id, layer_tree_host_impl_, show_delay,
1494 fade_out_delay, fade_out_resize_delay, fade_out_duration, 1496 fade_out_delay, fade_out_resize_delay, fade_in_duration,
1495 thinning_duration); 1497 fade_out_duration, thinning_duration);
1496 } 1498 }
1497 case LayerTreeSettings::NO_ANIMATOR: 1499 case LayerTreeSettings::NO_ANIMATOR:
1498 NOTREACHED(); 1500 NOTREACHED();
1499 break; 1501 break;
1500 } 1502 }
1501 return nullptr; 1503 return nullptr;
1502 } 1504 }
1503 1505
1504 void LayerTreeImpl::DidAnimateScrollOffset() { 1506 void LayerTreeImpl::DidAnimateScrollOffset() {
1505 layer_tree_host_impl_->DidAnimateScrollOffset(); 1507 layer_tree_host_impl_->DidAnimateScrollOffset();
(...skipping 674 matching lines...) Expand 10 before | Expand all | Expand 10 after
2180 2182
2181 void LayerTreeImpl::ResetAllChangeTracking() { 2183 void LayerTreeImpl::ResetAllChangeTracking() {
2182 layers_that_should_push_properties_.clear(); 2184 layers_that_should_push_properties_.clear();
2183 // Iterate over all layers, including masks. 2185 // Iterate over all layers, including masks.
2184 for (auto& layer : *layers_) 2186 for (auto& layer : *layers_)
2185 layer->ResetChangeTracking(); 2187 layer->ResetChangeTracking();
2186 property_trees_.ResetAllChangeTracking(); 2188 property_trees_.ResetAllChangeTracking();
2187 } 2189 }
2188 2190
2189 } // namespace cc 2191 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698