OLD | NEW |
1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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_INPUT_HANDLER_H_ | 5 #ifndef CC_INPUT_INPUT_HANDLER_H_ |
6 #define CC_INPUT_INPUT_HANDLER_H_ | 6 #define CC_INPUT_INPUT_HANDLER_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
124 virtual ScrollStatus ScrollBegin(ScrollState* scroll_state, | 124 virtual ScrollStatus ScrollBegin(ScrollState* scroll_state, |
125 ScrollInputType type) = 0; | 125 ScrollInputType type) = 0; |
126 | 126 |
127 // Similar to ScrollBegin, except the hit test is skipped and scroll always | 127 // Similar to ScrollBegin, except the hit test is skipped and scroll always |
128 // targets at the root layer. | 128 // targets at the root layer. |
129 virtual ScrollStatus RootScrollBegin(ScrollState* scroll_state, | 129 virtual ScrollStatus RootScrollBegin(ScrollState* scroll_state, |
130 ScrollInputType type) = 0; | 130 ScrollInputType type) = 0; |
131 | 131 |
132 // Returns SCROLL_ON_IMPL_THREAD if a layer is actively being scrolled or | 132 // Returns SCROLL_ON_IMPL_THREAD if a layer is actively being scrolled or |
133 // a subsequent call to ScrollAnimated can begin on the impl thread. | 133 // a subsequent call to ScrollAnimated can begin on the impl thread. |
134 virtual ScrollStatus ScrollAnimatedBegin( | 134 virtual ScrollStatus ScrollAnimatedBegin(ScrollState* scroll_state) = 0; |
135 const gfx::Point& viewport_point) = 0; | |
136 | 135 |
137 // Returns SCROLL_ON_IMPL_THREAD if an animation is initiated on the impl | 136 // Returns SCROLL_ON_IMPL_THREAD if an animation is initiated on the impl |
138 // thread. delayed_by is the delay that is taken into account when determining | 137 // thread. delayed_by is the delay that is taken into account when determining |
139 // the duration of the animation. | 138 // the duration of the animation. |
140 virtual ScrollStatus ScrollAnimated(const gfx::Point& viewport_point, | 139 virtual ScrollStatus ScrollAnimated(const gfx::Point& viewport_point, |
141 const gfx::Vector2dF& scroll_delta, | 140 const gfx::Vector2dF& scroll_delta, |
142 base::TimeDelta delayed_by) = 0; | 141 base::TimeDelta delayed_by) = 0; |
143 | 142 |
144 // Scroll the layer selected by |ScrollBegin| by given |scroll_state| delta. | 143 // Scroll the layer selected by |ScrollBegin| by given |scroll_state| delta. |
145 // Internally, the delta is transformed to local layer's coordinate space for | 144 // Internally, the delta is transformed to local layer's coordinate space for |
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
224 InputHandler() {} | 223 InputHandler() {} |
225 virtual ~InputHandler() {} | 224 virtual ~InputHandler() {} |
226 | 225 |
227 private: | 226 private: |
228 DISALLOW_COPY_AND_ASSIGN(InputHandler); | 227 DISALLOW_COPY_AND_ASSIGN(InputHandler); |
229 }; | 228 }; |
230 | 229 |
231 } // namespace cc | 230 } // namespace cc |
232 | 231 |
233 #endif // CC_INPUT_INPUT_HANDLER_H_ | 232 #endif // CC_INPUT_INPUT_HANDLER_H_ |
OLD | NEW |