OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CC_INPUT_TOP_CONTROLS_MANAGER_H_ | 5 #ifndef CC_INPUT_TOP_CONTROLS_MANAGER_H_ |
6 #define CC_INPUT_TOP_CONTROLS_MANAGER_H_ | 6 #define CC_INPUT_TOP_CONTROLS_MANAGER_H_ |
7 | 7 |
8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
9 #include "base/memory/weak_ptr.h" | 9 #include "base/memory/weak_ptr.h" |
10 #include "cc/input/top_controls_state.h" | 10 #include "cc/input/top_controls_state.h" |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
76 void SetupAnimation(AnimationDirection direction); | 76 void SetupAnimation(AnimationDirection direction); |
77 void StartAnimationIfNecessary(); | 77 void StartAnimationIfNecessary(); |
78 bool IsAnimationCompleteAtTime(base::TimeTicks time); | 78 bool IsAnimationCompleteAtTime(base::TimeTicks time); |
79 | 79 |
80 TopControlsManagerClient* client_; // The client manages the lifecycle of | 80 TopControlsManagerClient* client_; // The client manages the lifecycle of |
81 // this. | 81 // this. |
82 | 82 |
83 scoped_ptr<KeyframedFloatAnimationCurve> top_controls_animation_; | 83 scoped_ptr<KeyframedFloatAnimationCurve> top_controls_animation_; |
84 AnimationDirection animation_direction_; | 84 AnimationDirection animation_direction_; |
85 TopControlsState permitted_state_; | 85 TopControlsState permitted_state_; |
86 float controls_top_offset_; | |
87 float top_controls_height_; | 86 float top_controls_height_; |
88 | 87 |
89 float current_scroll_delta_; | 88 float current_scroll_delta_; |
90 float controls_scroll_begin_offset_; | 89 float controls_scroll_begin_offset_; |
91 | 90 |
92 // The height of the visible top control such that it must be shown when | 91 // The height of the visible top control such that it must be shown when |
93 // the user stops the scroll. | 92 // the user stops the scroll. |
94 float top_controls_show_height_; | 93 float top_controls_show_height_; |
95 | 94 |
96 // The height of the visible top control such that it must be hidden when | 95 // The height of the visible top control such that it must be hidden when |
97 // the user stops the scroll. | 96 // the user stops the scroll. |
98 float top_controls_hide_height_; | 97 float top_controls_hide_height_; |
99 | 98 |
100 bool pinch_gesture_active_; | 99 bool pinch_gesture_active_; |
101 | 100 |
102 DISALLOW_COPY_AND_ASSIGN(TopControlsManager); | 101 DISALLOW_COPY_AND_ASSIGN(TopControlsManager); |
103 }; | 102 }; |
104 | 103 |
105 } // namespace cc | 104 } // namespace cc |
106 | 105 |
107 #endif // CC_INPUT_TOP_CONTROLS_MANAGER_H_ | 106 #endif // CC_INPUT_TOP_CONTROLS_MANAGER_H_ |
OLD | NEW |