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

Unified Diff: third_party/WebKit/Source/core/style/ComputedStyleConstants.h

Issue 1422513006: Simplify TouchAction enum to be a simple bit flag (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix windows build warning Created 5 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/style/ComputedStyleConstants.h
diff --git a/third_party/WebKit/Source/core/style/ComputedStyleConstants.h b/third_party/WebKit/Source/core/style/ComputedStyleConstants.h
index fb72adffadc8c319be866003a1d936e4db5d80a9..aad34574dbfa09a820fedb9b8e957f5a402a4c5b 100644
--- a/third_party/WebKit/Source/core/style/ComputedStyleConstants.h
+++ b/third_party/WebKit/Source/core/style/ComputedStyleConstants.h
@@ -463,15 +463,18 @@ enum DraggableRegionMode { DraggableRegionNone, DraggableRegionDrag, DraggableRe
static const size_t TouchActionBits = 6;
enum TouchAction {
- TouchActionAuto = 0x0,
- TouchActionNone = 0x1,
- TouchActionPanLeft = 0x2,
- TouchActionPanRight = 0x4,
+ TouchActionNone = 0x0,
+ TouchActionPanLeft = 0x1,
+ TouchActionPanRight = 0x2,
TouchActionPanX = TouchActionPanLeft | TouchActionPanRight,
- TouchActionPanUp = 0x8,
- TouchActionPanDown = 0x10,
+ TouchActionPanUp = 0x4,
+ TouchActionPanDown = 0x8,
TouchActionPanY = TouchActionPanUp | TouchActionPanDown,
- TouchActionPinchZoom = 0x20,
+ TouchActionPan = TouchActionPanX | TouchActionPanY,
+ TouchActionPinchZoom = 0x10,
+ TouchActionManipulation = TouchActionPan | TouchActionPinchZoom,
+ TouchActionDoubleTapZoom = 0x20,
+ TouchActionAuto = TouchActionManipulation | TouchActionDoubleTapZoom
};
inline TouchAction operator| (TouchAction a, TouchAction b) { return TouchAction(int(a) | int(b)); }
inline TouchAction& operator|= (TouchAction& a, TouchAction b) { return a = a | b; }

Powered by Google App Engine
This is Rietveld 408576698