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

Unified Diff: cc/trees/layer_tree_impl.cc

Issue 2692243005: Merge Compositor's ScrollbarAnimationControllers into single class (Closed)
Patch Set: Created 3 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: cc/trees/layer_tree_impl.cc
diff --git a/cc/trees/layer_tree_impl.cc b/cc/trees/layer_tree_impl.cc
index ca0f8587a82bc6c479ad0066a2876913db19e478..0c5e016199e785d3abc59aa91121d7c7569f42e1 100644
--- a/cc/trees/layer_tree_impl.cc
+++ b/cc/trees/layer_tree_impl.cc
@@ -24,8 +24,6 @@
#include "cc/debug/traced_value.h"
#include "cc/input/page_scale_animation.h"
#include "cc/input/scrollbar_animation_controller.h"
-#include "cc/input/scrollbar_animation_controller_linear_fade.h"
-#include "cc/input/scrollbar_animation_controller_thinning.h"
#include "cc/layers/heads_up_display_layer_impl.h"
#include "cc/layers/layer.h"
#include "cc/layers/layer_iterator.h"
@@ -1379,16 +1377,18 @@ LayerTreeImpl::CreateScrollbarAnimationController(int scroll_layer_id) {
base::TimeDelta fade_duration = settings().scrollbar_fade_duration;
switch (settings().scrollbar_animator) {
case LayerTreeSettings::LINEAR_FADE: {
chaopeng 2017/02/15 19:59:50 I agree change name to ScrollbarAnimationControlle
weiliangc 2017/02/15 20:06:08 Yeah sounds good. Make sure to comment there too.
- return ScrollbarAnimationControllerLinearFade::Create(
- scroll_layer_id, layer_tree_host_impl_, delay, resize_delay,
- fade_duration);
+ return ScrollbarAnimationController::
+ CreateScrollbarAnimationControllerLinearFade(
+ scroll_layer_id, layer_tree_host_impl_, delay, resize_delay,
+ fade_duration);
}
case LayerTreeSettings::THINNING: {
base::TimeDelta thinning_duration =
settings().scrollbar_thinning_duration;
- return ScrollbarAnimationControllerThinning::Create(
- scroll_layer_id, layer_tree_host_impl_, delay, resize_delay,
- fade_duration, thinning_duration);
+ return ScrollbarAnimationController::
+ CreateScrollbarAnimationControllerThinning(
+ scroll_layer_id, layer_tree_host_impl_, delay, resize_delay,
+ fade_duration, thinning_duration);
}
case LayerTreeSettings::NO_ANIMATOR:
NOTREACHED();
« cc/input/scrollbar_animation_controller.cc ('K') | « cc/trees/layer_tree_host_impl_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698