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

Unified Diff: ui/chromeos/touch_exploration_controller.cc

Issue 429633002: Added multi-finger gestures to touch_exploration_controller (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@passthrough
Patch Set: updated swipe gesture code, added test Created 6 years, 4 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: ui/chromeos/touch_exploration_controller.cc
diff --git a/ui/chromeos/touch_exploration_controller.cc b/ui/chromeos/touch_exploration_controller.cc
index 6b2584afc7f2afc4c3d6bec3c3491e1fb11ae054..556d58b46f64510fc34e4b32bea92b3f57d50f92 100644
--- a/ui/chromeos/touch_exploration_controller.cc
+++ b/ui/chromeos/touch_exploration_controller.cc
@@ -6,6 +6,7 @@
#include "base/logging.h"
#include "base/strings/string_number_conversions.h"
+#include "base/time/default_tick_clock.h"
#include "ui/aura/client/cursor_client.h"
#include "ui/aura/window.h"
#include "ui/aura/window_event_dispatcher.h"
@@ -52,6 +53,13 @@ ui::EventRewriteStatus TouchExplorationController::RewriteEvent(
const ui::Event& event,
scoped_ptr<ui::Event>* rewritten_event) {
if (!event.IsTouchEvent()) {
+ if (event.IsKeyEvent()) {
+ const ui::KeyEvent& key_event = static_cast<const ui::KeyEvent&>(event);
+ VLOG(0) << "\nKeyboard event: " << key_event.name()
+ << "\n Key code: " << key_event.key_code()
+ << ", Flags: " << key_event.flags()
+ << ", Is char: " << key_event.is_char();
+ }
return ui::EVENT_REWRITE_CONTINUE;
}
const ui::TouchEvent& touch_event = static_cast<const ui::TouchEvent&>(event);
@@ -73,14 +81,21 @@ ui::EventRewriteStatus TouchExplorationController::RewriteEvent(
const gfx::PointF& location = touch_event.location_f();
const int touch_id = touch_event.touch_id();
+ // Always process gesture events in the gesture provider. Only one swipe
aboxhall 2014/08/04 23:38:53 I don't understand the second sentence of this com
evy 2014/08/05 00:14:40 Done.
+ // will be processed in touch_exploration_controller between
+ // NO_FINGERS_DOWN states.
+ gesture_provider_.OnTouchEvent(touch_event);
+ gesture_provider_.OnTouchEventAck(false);
+ ProcessGestureEvents();
+
// Always update touch ids and touch locations, so we can use those
// no matter what state we're in.
if (type == ui::ET_TOUCH_PRESSED) {
current_touch_ids_.push_back(touch_id);
touch_locations_.insert(std::pair<int, gfx::PointF>(touch_id, location));
} else if (type == ui::ET_TOUCH_RELEASED || type == ui::ET_TOUCH_CANCELLED) {
- // In order to avoid accidentally double tapping when moving off the edge of
- // the screen, the state will be rewritten to NoFingersDown.
+ // In order to avoid accidentally double tapping when moving off the edge
+ // of the screen, the state will be rewritten to NoFingersDown.
TouchEvent touch_event = static_cast<const TouchEvent&>(event);
if (FindEdgesWithinBounds(touch_event.location(), kLeavingScreenEdge) !=
NO_EDGE) {
@@ -111,7 +126,7 @@ ui::EventRewriteStatus TouchExplorationController::RewriteEvent(
VLOG_STATE();
VLOG_EVENT(touch_event);
// The rest of the processing depends on what state we're in.
- switch(state_) {
+ switch (state_) {
case NO_FINGERS_DOWN:
return InNoFingersDown(touch_event, rewritten_event);
case SINGLE_TAP_PRESSED:
@@ -129,12 +144,12 @@ ui::EventRewriteStatus TouchExplorationController::RewriteEvent(
return InGestureInProgress(touch_event, rewritten_event);
case TOUCH_EXPLORE_SECOND_PRESS:
return InTouchExploreSecondPress(touch_event, rewritten_event);
- case SLIDE_GESTURE:
- return InSlideGesture(touch_event, rewritten_event);
case ONE_FINGER_PASSTHROUGH:
return InOneFingerPassthrough(touch_event, rewritten_event);
- case WAIT_FOR_ONE_FINGER:
- return InWaitForOneFinger(touch_event, rewritten_event);
+ case WAIT_FOR_NO_FINGERS:
+ return InWaitForNoFingers(touch_event, rewritten_event);
+ case SLIDE_GESTURE:
+ return InSlideGesture(touch_event, rewritten_event);
}
NOTREACHED();
return ui::EVENT_REWRITE_CONTINUE;
@@ -153,9 +168,6 @@ ui::EventRewriteStatus TouchExplorationController::InNoFingersDown(
initial_press_.reset(new TouchEvent(event));
last_unused_finger_event_.reset(new TouchEvent(event));
StartTapTimer();
- gesture_provider_.OnTouchEvent(event);
- gesture_provider_.OnTouchEventAck(false);
- ProcessGestureEvents();
state_ = SINGLE_TAP_PRESSED;
VLOG_STATE();
return ui::EVENT_REWRITE_DISCARD;
@@ -169,10 +181,10 @@ ui::EventRewriteStatus TouchExplorationController::InSingleTapPressed(
const ui::EventType type = event.type();
if (type == ui::ET_TOUCH_PRESSED) {
- // TODO (evy, lisayin) : add support for multifinger swipes.
- // For now, we wait for there to be only one finger down again.
- state_ = WAIT_FOR_ONE_FINGER;
- return EVENT_REWRITE_DISCARD;
+ // This is the start of a multifinger gesture.
+ state_ = GESTURE_IN_PROGRESS;
+ VLOG_STATE();
+ return InGestureInProgress(event, rewritten_event);
} else if (type == ui::ET_TOUCH_RELEASED || type == ui::ET_TOUCH_CANCELLED) {
if (current_touch_ids_.size() == 0 &&
event.touch_id() == initial_press_->touch_id()) {
@@ -228,16 +240,18 @@ TouchExplorationController::InSingleTapOrTouchExploreReleased(
const ui::TouchEvent& event,
scoped_ptr<ui::Event>* rewritten_event) {
const ui::EventType type = event.type();
- // If there is more than one finger down, then discard to wait until only one
- // finger is or no fingers are down.
+ // If there is more than one finger down, then discard to wait until no
+ // fingers are down.
if (current_touch_ids_.size() > 1) {
- state_ = WAIT_FOR_ONE_FINGER;
+ state_ = WAIT_FOR_NO_FINGERS;
+ VLOG_STATE();
return ui::EVENT_REWRITE_DISCARD;
}
if (type == ui::ET_TOUCH_PRESSED) {
// If there is no touch exploration yet, we can't send a click, so discard.
if (!last_touch_exploration_) {
- tap_timer_.Stop();
+ if (tap_timer_.IsRunning())
aboxhall 2014/08/04 23:38:53 This check shouldn't be necessary: https://code.go
evy 2014/08/05 00:14:40 Thanks for catching that! Updated some other parts
+ tap_timer_.Stop();
return ui::EVENT_REWRITE_DISCARD;
}
// This is the second tap in a double-tap (or double tap-hold).
@@ -246,6 +260,10 @@ TouchExplorationController::InSingleTapOrTouchExploreReleased(
// release at the location of the last touch exploration.
state_ = DOUBLE_TAP_PENDING;
VLOG_STATE();
+ // The old tap timer (from the initial click) is stopped if it is still
+ // going, and the new one is set.
+ if (tap_timer_.IsRunning())
+ tap_timer_.Stop();
StartTapTimer();
// This will update as the finger moves before a possible passthrough, and
// will determine the offset.
@@ -365,32 +383,18 @@ ui::EventRewriteStatus TouchExplorationController::InGestureInProgress(
const ui::TouchEvent& event,
scoped_ptr<ui::Event>* rewritten_event) {
ui::EventType type = event.type();
- // If additional fingers are added before a swipe gesture has been
- // registered, then the state will no longer be GESTURE_IN_PROGRESS.
- if (type == ui::ET_TOUCH_PRESSED ||
- event.touch_id() != initial_press_->touch_id()) {
- if (tap_timer_.IsRunning())
- tap_timer_.Stop();
- // Discard any pending gestures.
- delete gesture_provider_.GetAndResetPendingGestures();
- state_ = WAIT_FOR_ONE_FINGER;
- return EVENT_REWRITE_DISCARD;
- }
-
- // There should not be more than one finger down.
- DCHECK(current_touch_ids_.size() <= 1);
- if (type == ui::ET_TOUCH_MOVED) {
- gesture_provider_.OnTouchEvent(event);
- gesture_provider_.OnTouchEventAck(false);
+ if (type != ui::ET_TOUCH_RELEASED && type != ui::ET_TOUCH_CANCELLED &&
+ type != ui::ET_TOUCH_MOVED && type != ui::ET_TOUCH_PRESSED) {
+ NOTREACHED() << "Unexpected event type received: " << event.name();
+ return ui::EVENT_REWRITE_CONTINUE;
}
- if (type == ui::ET_TOUCH_RELEASED || type == ui::ET_TOUCH_CANCELLED) {
- gesture_provider_.OnTouchEvent(event);
- gesture_provider_.OnTouchEventAck(false);
- if (current_touch_ids_.size() == 0) {
- ResetToNoFingersDown();
- }
+ // The events were sent to the gesture provider in RewriteEvent already.
+ // If no gesture is registered before the tap timer times out, the state
aboxhall 2014/08/04 23:38:53 So the gesture grace period is the same as the dou
evy 2014/08/05 00:14:40 Yes, any time in this code that the tap timer is s
+ // will change to wait for one finger and this function will stop being
+ // called.
+ if (current_touch_ids_.size() == 0) {
+ ResetToNoFingersDown();
}
- ProcessGestureEvents();
return ui::EVENT_REWRITE_DISCARD;
}
@@ -398,9 +402,8 @@ ui::EventRewriteStatus TouchExplorationController::InOneFingerPassthrough(
const ui::TouchEvent& event,
scoped_ptr<ui::Event>* rewritten_event) {
ui::EventType type = event.type();
-
- if (!(type == ui::ET_TOUCH_RELEASED || type == ui::ET_TOUCH_CANCELLED ||
- type == ui::ET_TOUCH_MOVED || type == ui::ET_TOUCH_PRESSED)) {
+ if (type != ui::ET_TOUCH_RELEASED && type != ui::ET_TOUCH_CANCELLED &&
+ type != ui::ET_TOUCH_MOVED && type != ui::ET_TOUCH_PRESSED) {
NOTREACHED() << "Unexpected event type received: " << event.name();
return ui::EVENT_REWRITE_CONTINUE;
}
@@ -466,7 +469,7 @@ ui::EventRewriteStatus TouchExplorationController::InTouchExploreSecondPress(
return ui::EVENT_REWRITE_CONTINUE;
}
-ui::EventRewriteStatus TouchExplorationController::InWaitForOneFinger(
+ui::EventRewriteStatus TouchExplorationController::InWaitForNoFingers(
const ui::TouchEvent& event,
scoped_ptr<ui::Event>* rewritten_event) {
ui::EventType type = event.type();
@@ -475,14 +478,10 @@ ui::EventRewriteStatus TouchExplorationController::InWaitForOneFinger(
NOTREACHED() << "Unexpected event type received: " << event.name();
return ui::EVENT_REWRITE_CONTINUE;
}
- if (current_touch_ids_.size() == 1) {
- EnterTouchToMouseMode();
- state_ = TOUCH_EXPLORATION;
- VLOG_STATE();
- *rewritten_event = CreateMouseMoveEvent(event.location(), event.flags());
- last_touch_exploration_.reset(new TouchEvent(event));
- return ui::EVENT_REWRITE_REWRITTEN;
- }
+
+ if (current_touch_ids_.size() == 0)
+ ResetToNoFingersDown();
+
return EVENT_REWRITE_DISCARD;
}
@@ -506,10 +505,15 @@ ui::EventRewriteStatus TouchExplorationController::InSlideGesture(
sound_timer_.Stop();
// Discard any pending gestures.
delete gesture_provider_.GetAndResetPendingGestures();
- state_ = WAIT_FOR_ONE_FINGER;
+ state_ = WAIT_FOR_NO_FINGERS;
+ VLOG_STATE();
return EVENT_REWRITE_DISCARD;
}
+ // There should not be more than one finger down.
+ DCHECK(current_touch_ids_.size() <= 1);
+
+
// Allows user to return to the edge to adjust the sound if they have left the
// boundaries.
int edge = FindEdgesWithinBounds(event.location(), kSlopDistanceFromEdge);
@@ -530,23 +534,10 @@ ui::EventRewriteStatus TouchExplorationController::InSlideGesture(
delegate_->PlayVolumeAdjustSound();
}
- // There should not be more than one finger down.
- DCHECK(current_touch_ids_.size() <= 1);
- if (type == ui::ET_TOUCH_MOVED) {
- gesture_provider_.OnTouchEvent(event);
- gesture_provider_.OnTouchEventAck(false);
- }
- if (type == ui::ET_TOUCH_RELEASED || type == ui::ET_TOUCH_CANCELLED) {
- gesture_provider_.OnTouchEvent(event);
- gesture_provider_.OnTouchEventAck(false);
- delete gesture_provider_.GetAndResetPendingGestures();
- if (current_touch_ids_.size() == 0) {
- ResetToNoFingersDown();
- }
- return ui::EVENT_REWRITE_DISCARD;
+ if (current_touch_ids_.size() == 0) {
+ ResetToNoFingersDown();
}
- ProcessGestureEvents();
return ui::EVENT_REWRITE_DISCARD;
}
@@ -590,13 +581,23 @@ void TouchExplorationController::OnTapTimerFired() {
return;
}
case SINGLE_TAP_PRESSED:
+ EnterTouchToMouseMode();
+ state_ = TOUCH_EXPLORATION;
+ break;
case GESTURE_IN_PROGRESS:
// Discard any pending gestures.
delete gesture_provider_.GetAndResetPendingGestures();
- EnterTouchToMouseMode();
- state_ = TOUCH_EXPLORATION;
+ // If only one finger is down, go into touch exploration.
+ if(current_touch_ids_.size() == 1){
aboxhall 2014/08/04 23:38:53 nit: space between if and (, and ) and {
evy 2014/08/05 00:14:40 Done.
+ EnterTouchToMouseMode();
+ state_ = TOUCH_EXPLORATION;
+ VLOG_STATE();
+ return;
+ }
+ // Otherwise wait for all fingers to be lifted.
+ state_ = WAIT_FOR_NO_FINGERS;
VLOG_STATE();
- break;
+ return;
default:
return;
}
@@ -619,13 +620,14 @@ void TouchExplorationController::OnGestureEvent(
ui::GestureEvent* gesture) {
CHECK(gesture->IsGestureEvent());
ui::EventType type = gesture->type();
- if (VLOG_on_)
- VLOG(0) << " \n Gesture Triggered: " << gesture->name();
- if (type == ui::ET_GESTURE_SWIPE && state_ != SLIDE_GESTURE) {
- if (VLOG_on_)
- VLOG(0) << "Swipe!";
+ if (type == ui::ET_GESTURE_SWIPE && state_ == GESTURE_IN_PROGRESS) {
delete gesture_provider_.GetAndResetPendingGestures();
OnSwipeEvent(gesture);
+ // The tap timer to leave gesture state is ended, and we now wait for all
+ // fingers to be released.
+ tap_timer_.Stop();
+ state_ = WAIT_FOR_NO_FINGERS;
+ VLOG_STATE();
return;
}
}
@@ -637,6 +639,10 @@ void TouchExplorationController::ProcessGestureEvents() {
for (ScopedVector<GestureEvent>::iterator i = gestures->begin();
i != gestures->end();
++i) {
+ if (VLOG_on_ &&
+ (state_ == SLIDE_GESTURE || state_ == GESTURE_IN_PROGRESS) &&
+ (*i)->type() == ui::ET_GESTURE_SWIPE)
+ VLOG(0) << " \n Gesture Triggered: " << (*i)->name();
if (state_ == SLIDE_GESTURE)
SideSlideControl(*i);
else
@@ -693,24 +699,80 @@ void TouchExplorationController::SideSlideControl(ui::GestureEvent* gesture) {
delegate_->SetOutputLevel(int(volume));
}
-
void TouchExplorationController::OnSwipeEvent(ui::GestureEvent* swipe_gesture) {
// A swipe gesture contains details for the direction in which the swipe
- // occurred.
+ // occurred. TODO(evy) : Research which swipe results users most want and
+ // remap these swipes to the best events. Hopefully in the near future
+ // there will also be a menu for users to pick custom mappings.
GestureEventDetails event_details = swipe_gesture->details();
- if (event_details.swipe_left()) {
- DispatchShiftSearchKeyEvent(ui::VKEY_LEFT);
- return;
- } else if (event_details.swipe_right()) {
- DispatchShiftSearchKeyEvent(ui::VKEY_RIGHT);
- return;
- } else if (event_details.swipe_up()) {
- DispatchShiftSearchKeyEvent(ui::VKEY_UP);
- return;
- } else if (event_details.swipe_down()) {
- DispatchShiftSearchKeyEvent(ui::VKEY_DOWN);
+ int num_fingers = event_details.touch_points();
+ if(VLOG_on_)
+ VLOG(0) << "\nSwipe with " << num_fingers << " fingers.";
+ if (num_fingers > 4)
return;
+ switch (num_fingers) {
+ case 1:
+ if (event_details.swipe_left()) {
+ DispatchShiftSearchKeyEvent(ui::VKEY_LEFT);
+ return;
+ } else if (event_details.swipe_right()) {
+ DispatchShiftSearchKeyEvent(ui::VKEY_RIGHT);
+ return;
+ } else if (event_details.swipe_up()) {
+ DispatchShiftSearchKeyEvent(ui::VKEY_UP);
+ return;
+ } else if (event_details.swipe_down()) {
+ DispatchShiftSearchKeyEvent(ui::VKEY_DOWN);
+ return;
+ }
+ case 2:
+ if (event_details.swipe_left()) {
+ DispatchKeyWithFlags(VKEY_BROWSER_BACK, ui::EF_NONE);
+ return;
+ } else if (event_details.swipe_right()) {
+ DispatchKeyWithFlags(VKEY_BROWSER_FORWARD, ui::EF_NONE);
+ return;
+ } else if (event_details.swipe_up()) {
+ DispatchShiftSearchKeyEvent(ui::VKEY_A);
+ return;
+ } else if (event_details.swipe_down()) {
+ DispatchShiftSearchKeyEvent(ui::VKEY_R);
+ return;
+ }
+ case 3:
+ if (event_details.swipe_left()) {
+ DispatchKeyWithFlags(ui::VKEY_TAB,
+ ui::EF_CONTROL_DOWN | ui::EF_SHIFT_DOWN);
+ } else if (event_details.swipe_right()) {
+ DispatchKeyWithFlags(ui::VKEY_TAB, ui::EF_CONTROL_DOWN);
+ } else if (event_details.swipe_up()) {
+ DispatchKeyWithFlags(ui::VKEY_NEXT, ui::EF_NONE);
+ return;
+ } else if (event_details.swipe_down()) {
+ DispatchKeyWithFlags(ui::VKEY_PRIOR, ui::EF_NONE);
+ return;
+ }
+ return;
+ case 4:
+ // Brightness can be important for vision users, but none of these
aboxhall 2014/08/04 23:38:53 nit: low vision users
evy 2014/08/05 00:14:40 Thanks! That's what I meant :)
+ // mappings are permanent. Four finger gestures shoudl probably
aboxhall 2014/08/04 23:38:53 nit: "shoudl"
evy 2014/08/05 00:14:40 Done.
+ // eventually be used for rare needs that are hard to access through
+ // menus.
+ if (event_details.swipe_left()) {
+ DispatchKeyWithFlags(VKEY_BRIGHTNESS_DOWN, ui::EF_NONE);
+ return;
+ } else if (event_details.swipe_right()) {
+ DispatchKeyWithFlags(VKEY_BRIGHTNESS_UP, ui::EF_NONE);
+ return;
+ } else if (event_details.swipe_up()) {
+ DispatchKeyWithFlags(VKEY_BROWSER_HOME, ui::EF_NONE);
+ return;
+ } else if (event_details.swipe_down()) {
+ DispatchKeyWithFlags(VKEY_BROWSER_REFRESH, ui::EF_NONE);
+ return;
+ }
}
+ return;
}
int TouchExplorationController::FindEdgesWithinBounds(gfx::Point point,
@@ -742,32 +804,45 @@ int TouchExplorationController::FindEdgesWithinBounds(gfx::Point point,
}
void TouchExplorationController::DispatchShiftSearchKeyEvent(
- const ui::KeyboardCode direction) {
- // In order to activate the shortcut shift+search+<arrow key>
+ const ui::KeyboardCode third_key) {
+ // In order to activate the shortcut shift+search+<key>
// three KeyPressed events must be dispatched in succession along
// with three KeyReleased events.
- ui::KeyEvent shift_down = ui::KeyEvent(
+
+ ui::KeyEvent shift_down(
ui::ET_KEY_PRESSED, ui::VKEY_SHIFT, ui::EF_SHIFT_DOWN);
- ui::KeyEvent search_down = ui::KeyEvent(
+ ui::KeyEvent search_down(
ui::ET_KEY_PRESSED, kChromeOSSearchKey, ui::EF_SHIFT_DOWN);
- ui::KeyEvent direction_down =
- ui::KeyEvent(ui::ET_KEY_PRESSED, direction, ui::EF_SHIFT_DOWN);
+ ui::KeyEvent third_key_down(ui::ET_KEY_PRESSED, third_key, ui::EF_SHIFT_DOWN);
- ui::KeyEvent direction_up =
- ui::KeyEvent(ui::ET_KEY_RELEASED, direction, ui::EF_SHIFT_DOWN);
- ui::KeyEvent search_up = ui::KeyEvent(
+ ui::KeyEvent third_key_up(ui::ET_KEY_RELEASED, third_key, ui::EF_SHIFT_DOWN);
+ ui::KeyEvent search_up(
ui::ET_KEY_RELEASED, kChromeOSSearchKey, ui::EF_SHIFT_DOWN);
- ui::KeyEvent shift_up =
- ui::KeyEvent(ui::ET_KEY_RELEASED, ui::VKEY_SHIFT, ui::EF_NONE);
+ ui ::KeyEvent shift_up(ui::ET_KEY_RELEASED, ui::VKEY_SHIFT, ui::EF_NONE);
DispatchEvent(&shift_down);
DispatchEvent(&search_down);
- DispatchEvent(&direction_down);
- DispatchEvent(&direction_up);
+ DispatchEvent(&third_key_down);
+ DispatchEvent(&third_key_up);
DispatchEvent(&search_up);
DispatchEvent(&shift_up);
}
+void TouchExplorationController::DispatchKeyWithFlags(
+ const ui::KeyboardCode key,
+ int flags) {
+ ui::KeyEvent key_down(ui::ET_KEY_PRESSED, key, flags);
+ ui::KeyEvent key_up(ui::ET_KEY_RELEASED, key, flags);
+ DispatchEvent(&key_down);
+ DispatchEvent(&key_up);
+ if(VLOG_on_) {
+ VLOG(0) << "\nKey down: key code : " << key_down.key_code()
+ << ", flags: " << key_down.flags()
+ << "\nKey up: key code : " << key_up.key_code()
+ << ", flags: " << key_up.flags();
+ }
+}
+
scoped_ptr<ui::Event> TouchExplorationController::CreateMouseMoveEvent(
const gfx::PointF& location,
int flags) {
@@ -843,6 +918,7 @@ void TouchExplorationController::VlogEvent(const ui::TouchEvent& touch_event,
touch_event.type() == ET_TOUCH_MOVED){
return;
}
+
const std::string& type = touch_event.name();
const gfx::PointF& location = touch_event.location_f();
const int touch_id = touch_event.touch_id();
@@ -874,12 +950,12 @@ const char* TouchExplorationController::EnumStateToString(State state) {
return "GESTURE_IN_PROGRESS";
case TOUCH_EXPLORE_SECOND_PRESS:
return "TOUCH_EXPLORE_SECOND_PRESS";
- case SLIDE_GESTURE:
- return "SLIDE_GESTURE";
case ONE_FINGER_PASSTHROUGH:
return "ONE_FINGER_PASSTHROUGH";
- case WAIT_FOR_ONE_FINGER:
- return "WAIT_FOR_ONE_FINGER";
+ case WAIT_FOR_NO_FINGERS:
+ return "WAIT_FOR_NO_FINGERS";
+ case SLIDE_GESTURE:
+ return "SLIDE_GESTURE";
}
return "Not a state";
}

Powered by Google App Engine
This is Rietveld 408576698