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

Side by Side Diff: ui/compositor/test/test_layer_animation_observer.h

Issue 851853002: It is time. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Trying to reup because the last upload failed. Created 5 years, 11 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
(Empty)
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef UI_COMPOSITOR_TEST_TEST_LAYER_ANIMATION_OBSERVER_H_
6 #define UI_COMPOSITOR_TEST_TEST_LAYER_ANIMATION_OBSERVER_H_
7
8 #include "base/compiler_specific.h"
9 #include "ui/compositor/layer_animation_observer.h"
10
11 namespace ui {
12
13 class LayerAnimationSequence;
14
15 // Listens to animation ended notifications. Remembers the last sequence that
16 // it was notified about.
17 class TestLayerAnimationObserver : public LayerAnimationObserver {
18 public:
19 TestLayerAnimationObserver();
20 ~TestLayerAnimationObserver() override;
21
22 void OnLayerAnimationEnded(LayerAnimationSequence* sequence) override;
23
24 void OnLayerAnimationAborted(LayerAnimationSequence* sequence) override;
25
26 void OnLayerAnimationScheduled(LayerAnimationSequence* sequence) override;
27
28 bool RequiresNotificationWhenAnimatorDestroyed() const override;
29
30 const LayerAnimationSequence* last_ended_sequence() const {
31 return last_ended_sequence_;
32 }
33
34 const LayerAnimationSequence* last_scheduled_sequence() const {
35 return last_scheduled_sequence_;
36 }
37
38 const LayerAnimationSequence* last_aborted_sequence() const {
39 return last_aborted_sequence_;
40 }
41
42 void set_requires_notification_when_animator_destroyed(bool value) {
43 requires_notification_when_animator_destroyed_ = value;
44 }
45
46 private:
47 const LayerAnimationSequence* last_ended_sequence_;
48 const LayerAnimationSequence* last_scheduled_sequence_;
49 const LayerAnimationSequence* last_aborted_sequence_;
50 bool requires_notification_when_animator_destroyed_;
51
52 // Copy and assign are allowed.
53 };
54
55 } // namespace ui
56
57 #endif // UI_COMPOSITOR_TEST_TEST_LAYER_ANIMATION_OBSERVER_H_
OLDNEW
« no previous file with comments | « ui/compositor/test/test_layer_animation_delegate.cc ('k') | ui/compositor/test/test_layer_animation_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698