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

Unified Diff: ui/compositor/layer_animation_sequence.cc

Issue 1381463002: Added LayerAnimationObserver::OnLayerAnimationStarted() notification. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Polish after self review. 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 side-by-side diff with in-line comments
Download patch
Index: ui/compositor/layer_animation_sequence.cc
diff --git a/ui/compositor/layer_animation_sequence.cc b/ui/compositor/layer_animation_sequence.cc
index 2c01a22d4c04dfb90989dc946486549b7e7f89fb..04a91af2ae3634866bb92c93f5cad70da75754df 100644
--- a/ui/compositor/layer_animation_sequence.cc
+++ b/ui/compositor/layer_animation_sequence.cc
@@ -48,6 +48,8 @@ void LayerAnimationSequence::Start(LayerAnimationDelegate* delegate) {
if (elements_.empty())
return;
+ NotifyStarted();
+
elements_[0]->set_requested_start_time(start_time_);
elements_[0]->Start(delegate, animation_group_id_);
}
@@ -258,6 +260,11 @@ void LayerAnimationSequence::NotifyScheduled() {
OnLayerAnimationScheduled(this));
}
+void LayerAnimationSequence::NotifyStarted() {
+ FOR_EACH_OBSERVER(LayerAnimationObserver, observers_,
+ OnLayerAnimationStarted(this));
+}
+
void LayerAnimationSequence::NotifyEnded() {
FOR_EACH_OBSERVER(LayerAnimationObserver,
observers_,

Powered by Google App Engine
This is Rietveld 408576698