base: Change DCHECK_IS_ON to a macro DCHECK_IS_ON().
[chromium-blink-merge.git] / ui / compositor / test / layer_animator_test_controller.h
blob0f8d1e8a3a4735e03a9ba43710064bd633451c95
1 // Copyright (c) 2013 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.
5 #ifndef UI_COMPOSITOR_TEST_LAYER_ANIMATOR_TEST_CONTROLLER_H_
6 #define UI_COMPOSITOR_TEST_LAYER_ANIMATOR_TEST_CONTROLLER_H_
8 #include "ui/compositor/layer_animator.h"
10 namespace ui {
12 // Allows tests to access sequences owned by the animator.
13 class LayerAnimatorTestController {
14 public:
15 LayerAnimatorTestController(scoped_refptr<LayerAnimator> animator);
17 ~LayerAnimatorTestController();
19 LayerAnimator* animator() { return animator_.get(); }
21 // Returns the running sequence animating the given property, if any.
22 LayerAnimationSequence* GetRunningSequence(
23 LayerAnimationElement::AnimatableProperty property);
25 // Starts threaded animations that are waiting for an effective start time.
26 void StartThreadedAnimationsIfNeeded();
28 private:
29 scoped_refptr<LayerAnimator> animator_;
32 } // namespace ui
34 #endif // UI_COMPOSITOR_TEST_LAYER_ANIMATOR_TEST_CONTROLLER_H_