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

Unified Diff: ui/base/gestures/gesture_types.h

Issue 10937038: gesture recognizer: Recognizer rotation gestures. Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 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
« no previous file with comments | « ui/base/gestures/gesture_sequence.cc ('k') | ui/base/gestures/gesture_types.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/gestures/gesture_types.h
diff --git a/ui/base/gestures/gesture_types.h b/ui/base/gestures/gesture_types.h
index d44de87f119b9107b295a5d7e3938241a5d90015..2e8ef2c4f49d36f3c212edea0413f589ad193904 100644
--- a/ui/base/gestures/gesture_types.h
+++ b/ui/base/gestures/gesture_types.h
@@ -60,7 +60,12 @@ struct UI_EXPORT GestureEventDetails {
float scale() const {
CHECK_EQ(ui::ET_GESTURE_PINCH_UPDATE, type_);
- return data.scale;
+ return data.pinch.scale;
+ }
+
+ float rotation() const {
+ CHECK_EQ(ui::ET_GESTURE_PINCH_UPDATE, type_);
+ return data.pinch.rotation;
}
bool swipe_left() const {
@@ -98,7 +103,10 @@ struct UI_EXPORT GestureEventDetails {
float velocity_y;
} scroll_update;
- float scale; // PINCH scale.
+ struct { // PINCH scale, rotation.
+ float scale;
+ float rotation;
+ } pinch;
struct { // FLING velocity.
float x;
« no previous file with comments | « ui/base/gestures/gesture_sequence.cc ('k') | ui/base/gestures/gesture_types.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698