Code example for Scroller

Methods: abortAnimation

0
post(updater);
    } 
 
    public void onGestureStart(MotionEvent event) {
        scroller.abortAnimation();
    } 
 
    public void onFingerStart(int index, MotionEvent event) {/*pass*/}
 
    public void onFingerEnd(int index, MotionEvent event) {/*pass*/}
 
    public void onGestureEnd(MotionEvent event) {
        Log.w(getClass().getSimpleName(), "onGestureEnd");
    } 
     
    private class ScrollUpdater implements Runnable {
        public void run() { 
            if (scroller.computeScrollOffset()){
                scrollTo(scroller.getCurrX(), 0);
                post(this);