Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(25)

Side by Side Diff: third_party/WebKit/public/platform/WebGestureEvent.h

Issue 2573073003: Collapse the API surface on WebInputEvent via accessor functions. (Closed)
Patch Set: Fix nits Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 WebGestureEvent_h 5 #ifndef WebGestureEvent_h
6 #define WebGestureEvent_h 6 #define WebGestureEvent_h
7 7
8 #include "WebFloatSize.h" 8 #include "WebFloatSize.h"
9 #include "WebGestureDevice.h" 9 #include "WebGestureDevice.h"
10 #include "WebInputEvent.h" 10 #include "WebInputEvent.h"
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 WebFloatPoint rootFrameCoords); 187 WebFloatPoint rootFrameCoords);
188 188
189 // Sets any scaled values to be their computed values and sets |frameScale| 189 // Sets any scaled values to be their computed values and sets |frameScale|
190 // back to 1 and |translateX|, |translateY| back to 0. 190 // back to 1 and |translateX|, |translateY| back to 0.
191 BLINK_PLATFORM_EXPORT void flattenTransform(); 191 BLINK_PLATFORM_EXPORT void flattenTransform();
192 192
193 bool preventPropagation() const { 193 bool preventPropagation() const {
194 // TODO(tdresser) Once we've decided if we're getting rid of scroll 194 // TODO(tdresser) Once we've decided if we're getting rid of scroll
195 // chaining, we should remove all scroll chaining related logic. See 195 // chaining, we should remove all scroll chaining related logic. See
196 // crbug.com/526462 for details. 196 // crbug.com/526462 for details.
197 DCHECK(type == WebInputEvent::GestureScrollUpdate); 197 DCHECK(m_type == WebInputEvent::GestureScrollUpdate);
198 return true; 198 return true;
199 } 199 }
200 200
201 bool isScrollEvent() const { 201 bool isScrollEvent() const {
202 switch (type) { 202 switch (m_type) {
203 case GestureScrollBegin: 203 case GestureScrollBegin:
204 case GestureScrollEnd: 204 case GestureScrollEnd:
205 case GestureScrollUpdate: 205 case GestureScrollUpdate:
206 case GestureFlingStart: 206 case GestureFlingStart:
207 case GesturePinchBegin: 207 case GesturePinchBegin:
208 case GesturePinchEnd: 208 case GesturePinchEnd:
209 case GesturePinchUpdate: 209 case GesturePinchUpdate:
210 return true; 210 return true;
211 case GestureTap: 211 case GestureTap:
212 case GestureTapUnconfirmed: 212 case GestureTapUnconfirmed:
(...skipping 11 matching lines...) Expand all
224 } 224 }
225 225
226 #endif 226 #endif
227 }; 227 };
228 228
229 #pragma pack(pop) 229 #pragma pack(pop)
230 230
231 } // namespace blink 231 } // namespace blink
232 232
233 #endif // WebGestureEvent_h 233 #endif // WebGestureEvent_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/tests/WebViewTest.cpp ('k') | third_party/WebKit/public/platform/WebInputEvent.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698