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 ASH_SCREEN_ROTATION_H_ | 5 #ifndef ASH_SCREEN_ROTATION_H_ |
6 #define ASH_SCREEN_ROTATION_H_ | 6 #define ASH_SCREEN_ROTATION_H_ |
7 | 7 |
8 #include "ash/ash_export.h" | 8 #include "ash/ash_export.h" |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 23 matching lines...) Expand all Loading... |
34 // objects are required to outlive the Screen rotation object. | 34 // objects are required to outlive the Screen rotation object. |
35 ScreenRotation(int degrees); | 35 ScreenRotation(int degrees); |
36 virtual ~ScreenRotation(); | 36 virtual ~ScreenRotation(); |
37 | 37 |
38 private: | 38 private: |
39 // Implementation of ui::LayerAnimationDelegate | 39 // Implementation of ui::LayerAnimationDelegate |
40 virtual void OnStart(ui::LayerAnimationDelegate* delegate) OVERRIDE; | 40 virtual void OnStart(ui::LayerAnimationDelegate* delegate) OVERRIDE; |
41 virtual bool OnProgress(double t, | 41 virtual bool OnProgress(double t, |
42 ui::LayerAnimationDelegate* delegate) OVERRIDE; | 42 ui::LayerAnimationDelegate* delegate) OVERRIDE; |
43 virtual void OnGetTarget(TargetValue* target) const OVERRIDE; | 43 virtual void OnGetTarget(TargetValue* target) const OVERRIDE; |
44 virtual void OnAbort() OVERRIDE; | 44 virtual void OnAbort(ui::LayerAnimationDelegate* delegate) OVERRIDE; |
45 | 45 |
46 static const ui::LayerAnimationElement::AnimatableProperties& | 46 static const ui::LayerAnimationElement::AnimatableProperties& |
47 GetProperties(); | 47 GetProperties(); |
48 | 48 |
49 // Generates the intermediate transformation matrices used during the | 49 // Generates the intermediate transformation matrices used during the |
50 // animation. | 50 // animation. |
51 scoped_ptr<ui::InterpolatedTransform> interpolated_transform_; | 51 scoped_ptr<ui::InterpolatedTransform> interpolated_transform_; |
52 | 52 |
53 // The number of degrees to rotate. | 53 // The number of degrees to rotate. |
54 int degrees_; | 54 int degrees_; |
55 | 55 |
56 // The target origin | 56 // The target origin |
57 gfx::Point new_origin_; | 57 gfx::Point new_origin_; |
58 | 58 |
59 DISALLOW_COPY_AND_ASSIGN(ScreenRotation); | 59 DISALLOW_COPY_AND_ASSIGN(ScreenRotation); |
60 }; | 60 }; |
61 | 61 |
62 } // namespace ash | 62 } // namespace ash |
63 | 63 |
64 #endif // ASH_SCREEN_ROTATION_H_ | 64 #endif // ASH_SCREEN_ROTATION_H_ |
OLD | NEW |