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

Unified Diff: cc/input/scrollbar_animation_controller_linear_fade.cc

Issue 2273933002: cc : Delete LayerImpl::OnOpacityAnimated (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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/input/scrollbar_animation_controller_linear_fade.cc
diff --git a/cc/input/scrollbar_animation_controller_linear_fade.cc b/cc/input/scrollbar_animation_controller_linear_fade.cc
index 8ead32491a3f9eebd4ccc55b1bdb3f77ab04cf89..56fd2d1eeba5f2628c02a7a0caeb9000cdbeccd3 100644
--- a/cc/input/scrollbar_animation_controller_linear_fade.cc
+++ b/cc/input/scrollbar_animation_controller_linear_fade.cc
@@ -8,6 +8,7 @@
#include "base/time/time.h"
#include "cc/layers/layer_impl.h"
#include "cc/layers/scrollbar_layer_impl_base.h"
+#include "cc/trees/layer_tree_impl.h"
namespace cc {
@@ -55,8 +56,15 @@ void ScrollbarAnimationControllerLinearFade::ApplyOpacityToScrollbars(
for (ScrollbarLayerImplBase* scrollbar : Scrollbars()) {
if (!scrollbar->is_overlay_scrollbar())
continue;
- scrollbar->OnOpacityAnimated(scrollbar->CanScrollOrientation() ? opacity
- : 0);
+ PropertyTrees* property_trees =
+ scrollbar->layer_tree_impl()->property_trees();
+ if (property_trees->IsInIdToIndexMap(PropertyTrees::TreeType::EFFECT,
+ scrollbar->id())) {
+ property_trees->effect_tree.OnOpacityAnimated(
+ scrollbar->CanScrollOrientation() ? opacity : 0,
+ property_trees->effect_id_to_index_map[scrollbar->id()],
+ scrollbar->layer_tree_impl());
+ }
jaydasika 2016/08/23 23:12:01 OnOpacityAnimated can be called during layer's Pus
ajuma 2016/08/23 23:48:16 Please add a comment about this.
jaydasika 2016/08/24 00:37:46 Done.
}
}

Powered by Google App Engine
This is Rietveld 408576698