OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2011 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
201 case GestureTwoFingerTap: | 201 case GestureTwoFingerTap: |
202 case GestureLongPress: | 202 case GestureLongPress: |
203 case GestureLongTap: | 203 case GestureLongTap: |
204 return false; | 204 return false; |
205 default: | 205 default: |
206 ASSERT_NOT_REACHED(); | 206 ASSERT_NOT_REACHED(); |
207 return false; | 207 return false; |
208 } | 208 } |
209 } | 209 } |
210 | 210 |
| 211 uint32_t uniqueTouchEventId() const |
| 212 { |
| 213 return m_uniqueTouchEventId; |
| 214 } |
| 215 |
211 protected: | 216 protected: |
212 IntPoint m_position; | 217 IntPoint m_position; |
213 IntPoint m_globalPosition; | 218 IntPoint m_globalPosition; |
214 IntSize m_area; | 219 IntSize m_area; |
215 PlatformGestureSource m_source; | 220 PlatformGestureSource m_source; |
216 | 221 |
217 union { | 222 union { |
218 struct { | 223 struct { |
219 int m_tapCount; | 224 int m_tapCount; |
220 } m_tap; | 225 } m_tap; |
221 | 226 |
222 struct { | 227 struct { |
223 // |m_deltaX| and |m_deltaY| represent deltas in GSU but | 228 // |m_deltaX| and |m_deltaY| represent deltas in GSU but |
224 // are only hints in GSB. | 229 // are only hints in GSB. |
225 float m_deltaX; | 230 float m_deltaX; |
226 float m_deltaY; | 231 float m_deltaY; |
227 float m_velocityX; | 232 float m_velocityX; |
228 float m_velocityY; | 233 float m_velocityY; |
229 int m_preventPropagation; | 234 int m_preventPropagation; |
230 bool m_inertial; | 235 bool m_inertial; |
231 ScrollGranularity m_deltaUnits; | 236 ScrollGranularity m_deltaUnits; |
232 int m_resendingPluginId; | 237 int m_resendingPluginId; |
233 bool m_synthetic; | 238 bool m_synthetic; |
234 } m_scroll; | 239 } m_scroll; |
235 | 240 |
236 struct { | 241 struct { |
237 float m_scale; | 242 float m_scale; |
238 } m_pinchUpdate; | 243 } m_pinchUpdate; |
239 } m_data; | 244 } m_data; |
| 245 |
| 246 uint32_t m_uniqueTouchEventId; |
240 }; | 247 }; |
241 | 248 |
242 } // namespace blink | 249 } // namespace blink |
243 | 250 |
244 #endif // PlatformGestureEvent_h | 251 #endif // PlatformGestureEvent_h |
OLD | NEW |