| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef UI_COMPOSITOR_LAYER_ANIMATOR_H_ | 5 #ifndef UI_COMPOSITOR_LAYER_ANIMATOR_H_ |
| 6 #define UI_COMPOSITOR_LAYER_ANIMATOR_H_ | 6 #define UI_COMPOSITOR_LAYER_ANIMATOR_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 95 float GetTargetBrightness() const; | 95 float GetTargetBrightness() const; |
| 96 | 96 |
| 97 // Sets the grayscale on the delegate. May cause an implicit animation. | 97 // Sets the grayscale on the delegate. May cause an implicit animation. |
| 98 virtual void SetGrayscale(float grayscale); | 98 virtual void SetGrayscale(float grayscale); |
| 99 float GetTargetGrayscale() const; | 99 float GetTargetGrayscale() const; |
| 100 | 100 |
| 101 // Sets the color on the delegate. May cause an implicit animation. | 101 // Sets the color on the delegate. May cause an implicit animation. |
| 102 virtual void SetColor(SkColor color); | 102 virtual void SetColor(SkColor color); |
| 103 SkColor GetTargetColor() const; | 103 SkColor GetTargetColor() const; |
| 104 | 104 |
| 105 // Sets the color temperature on the delegate. May cause an implicit |
| 106 // animation. |
| 107 virtual void SetTemperature(float temperature); |
| 108 float GetTargetTemperature() const; |
| 109 |
| 105 // Returns the default length of animations, including adjustment for slow | 110 // Returns the default length of animations, including adjustment for slow |
| 106 // animation mode if set. | 111 // animation mode if set. |
| 107 base::TimeDelta GetTransitionDuration() const; | 112 base::TimeDelta GetTransitionDuration() const; |
| 108 | 113 |
| 109 // Sets the layer animation delegate the animator is associated with. The | 114 // Sets the layer animation delegate the animator is associated with. The |
| 110 // animator does not own the delegate. The layer animator expects a non-NULL | 115 // animator does not own the delegate. The layer animator expects a non-NULL |
| 111 // delegate for most of its operations, so do not call any methods without | 116 // delegate for most of its operations, so do not call any methods without |
| 112 // a valid delegate installed. | 117 // a valid delegate installed. |
| 113 void SetDelegate(LayerAnimationDelegate* delegate); | 118 void SetDelegate(LayerAnimationDelegate* delegate); |
| 114 | 119 |
| (...skipping 296 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 411 // Observers are notified when layer animations end, are scheduled or are | 416 // Observers are notified when layer animations end, are scheduled or are |
| 412 // aborted. | 417 // aborted. |
| 413 base::ObserverList<LayerAnimationObserver> observers_; | 418 base::ObserverList<LayerAnimationObserver> observers_; |
| 414 | 419 |
| 415 DISALLOW_COPY_AND_ASSIGN(LayerAnimator); | 420 DISALLOW_COPY_AND_ASSIGN(LayerAnimator); |
| 416 }; | 421 }; |
| 417 | 422 |
| 418 } // namespace ui | 423 } // namespace ui |
| 419 | 424 |
| 420 #endif // UI_COMPOSITOR_LAYER_ANIMATOR_H_ | 425 #endif // UI_COMPOSITOR_LAYER_ANIMATOR_H_ |
| OLD | NEW |