From 248ca5bfaf8729ac56b3b2af304797118085a975 Mon Sep 17 00:00:00 2001 From: "sadrul@chromium.org" Date: Tue, 28 Feb 2012 17:35:38 +0000 Subject: Revert 123989 sicne it broke aura_shell_unittests: --- Gestures are now possible using touch events with any ids Each gesture point stores a "point_id," which is used for state transitions in the GestureRecognizer. The point_ids are maintained such that the set of point_ids is always contiguous, from 0 to the number of current touches. A lower point_id indicates that a touch occurred first. BUG=113144 TEST=GestureRecognizerTest.* Review URL: http://codereview.chromium.org/9452024 TBR=tdresser@chromium.org Review URL: https://chromiumcodereview.appspot.com/9501004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@123991 0039d316-1c4b-4281-b951-d872f2087c98 --- ui/aura/gestures/gesture_point.h | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) (limited to 'ui/aura/gestures/gesture_point.h') diff --git a/ui/aura/gestures/gesture_point.h b/ui/aura/gestures/gesture_point.h index 906ba48..b04ffbd 100644 --- a/ui/aura/gestures/gesture_point.h +++ b/ui/aura/gestures/gesture_point.h @@ -53,16 +53,8 @@ class GesturePoint { double last_touch_time() const { return last_touch_time_; } const gfx::Point& last_touch_position() const { return last_touch_position_; } - // point_id_ is used to drive GestureSequence::ProcessTouchEventForGesture. - // point_ids are maintained such that the set of point_ids is always - // contiguous, from 0 to the number of current touches. - // A lower point_id indicates that a touch occurred first. - // A negative point_id indicates that the GesturePoint is not currently - // associated with a touch. - void set_point_id(int point_id) { point_id_ = point_id; } - const int point_id() const { return point_id_; } - - const bool in_use() const { return point_id_ >= 0; } + void set_touch_id(unsigned int touch_id) { touch_id_ = touch_id; } + unsigned int touch_id() const { return touch_id_; } double x_delta() const { return last_touch_position_.x() - first_touch_position_.x(); @@ -95,7 +87,7 @@ class GesturePoint { VelocityCalculator velocity_calculator_; - int point_id_; + unsigned int touch_id_; DISALLOW_COPY_AND_ASSIGN(GesturePoint); }; -- cgit v1.1