Code example for OverScroller

Methods: computeScrollOffsetgetCurrVelocitygetCurrX

0
		init(context);
	} 
 
	@Override 
	public void computeScroll() { 
		if (mScroller.computeScrollOffset()) {
			int oldX = getScrollX();
			int x = mScroller.getCurrX();
 
			if (oldX != x) {
				overScrollBy(x - oldX, 0, oldX, 0, mScrollRange, 0, mOverflingDistance, 0, false);
				onScrollChanged(x, 0, oldX, 0);
 
				if (x < 0 && oldX >= 0) {
					mEdgeEffectLeft.onAbsorb((int) mScroller.getCurrVelocity());
				} else if (x > mScrollRange && oldX <= mScrollRange) {
					mEdgeEffectRight.onAbsorb((int) mScroller.getCurrVelocity());
				} 
			} 
		} 
	} 
 
Stop searching for code, let great code find you!  Add Codota to your java IDE