Code example for HorizontalScrollView

Methods: scrollBy

0
                break; 
            case MotionEvent.ACTION_UP:
                curX = event.getX();
                curY = event.getY();
                vScroll.scrollBy((int) (mx - curX), (int) (my - curY));
                hScroll.scrollBy((int) (mx - curX), (int) (my - curY));
                break; 
        } 
 
        return true; 
    } 
 
}