I would like to know if it's possible to use glass gestures on the touch-pad to implement a number picker. The goal is that when you swipe forward and back a number displayed on the screen increases when you swipe forwards and decreases when you swipe back.
As mentioned in the comment, the Timer sample's
SetTimerActivity
uses aGestureDetector
to detect motion events on the touchpad and change the value accordingly.The main logic is in the
ScrollListener#onScroll
implementation:The other listener implementations are used for adding some physic simulation such as an inertial scrolling effect when the user swipes fast enough.