private void updateOverscrollAnimation(final int scrolledOffset){
  if (mEdgeGlowLeft == null || mEdgeGlowRight == null)   return;
  int nextScrollPosition=mCurrentX + scrolledOffset;
  if (mFlingTracker == null || mFlingTracker.isFinished()) {
    if (nextScrollPosition < 0) {
      if (mOnScrollBorderChangedListener != null) {
        mOnScrollBorderChangedListener.onScrollBorderChanged(OnScrollBorderChangedListener.ScrollState.SCROLL_STATE_START);
      }
      int overscroll=Math.abs(scrolledOffset);
      mEdgeGlowLeft.onPull((float)overscroll / getRenderWidth());
      if (!mEdgeGlowRight.isFinished()) {
        mEdgeGlowRight.onRelease();
      }
    }
 else     if (nextScrollPosition > mMaxX) {
      if (mOnScrollBorderChangedListener != null) {
        mOnScrollBorderChangedListener.onScrollBorderChanged(OnScrollBorderChangedListener.ScrollState.SCROLL_STATE_END);
      }
      int overscroll=Math.abs(scrolledOffset);
      mEdgeGlowRight.onPull((float)overscroll / getRenderWidth());
      if (!mEdgeGlowLeft.isFinished()) {
        mEdgeGlowLeft.onRelease();
      }
    }
 else {
      if (mOnScrollBorderChangedListener != null) {
        mOnScrollBorderChangedListener.onScrollBorderChanged(OnScrollBorderChangedListener.ScrollState.SCROLL_STATE_CENTER);
      }
    }
  }
}

private void updateOverscrollAnimation ( final int scrolledOffset ) { if ( mEdgeGlowLeft == null || mEdgeGlowRight == null ) return ; int nextScrollPosition = mCurrentX + scrolledOffset ; if ( mFlingTracker == null || mFlingTracker . isFinished ( ) ) { if ( nextScrollPosition < 0 ) { if ( mOnScrollBorderChangedListener != null ) { mOnScrollBorderChangedListener . onScrollBorderChanged ( OnScrollBorderChangedListener . ScrollState . SCROLL_STATE_START ) ; } int overscroll = Math . abs ( scrolledOffset ) ; mEdgeGlowLeft . onPull ( ( float ) overscroll / getRenderWidth ( ) ) ; if ( ! mEdgeGlowRight . isFinished ( ) ) { mEdgeGlowRight . onRelease ( ) ; } } else if ( nextScrollPosition > mMaxX ) { if ( mOnScrollBorderChangedListener != null ) { mOnScrollBorderChangedListener . onScrollBorderChanged ( OnScrollBorderChangedListener . ScrollState . SCROLL_STATE_END ) ; } int overscroll = Math . abs ( scrolledOffset ) ; mEdgeGlowRight . onPull ( ( float ) overscroll / getRenderWidth ( ) ) ; if ( ! mEdgeGlowLeft . isFinished ( ) ) { mEdgeGlowLeft . onRelease ( ) ; } } else { if ( mOnScrollBorderChangedListener != null ) { mOnScrollBorderChangedListener . onScrollBorderChanged ( OnScrollBorderChangedListener . ScrollState . SCROLL_STATE_CENTER ) ; } } } }
updates the over scroll animation based on the scrolled offset .
