@Override public void draw(Canvas canvas){
  super.draw(canvas);
  if (mEdgeGlowTop != null) {
    final int scrollX=getScrollX();
    if (!mEdgeGlowTop.isFinished()) {
      final int restoreCount=canvas.save();
      final int topPadding=mListPadding.top + mGlowPaddingTop;
      final int bottomPadding=mListPadding.bottom + mGlowPaddingBottom;
      final int height=getHeight() - topPadding - bottomPadding;
      int edgeX=Math.min(0,scrollX + mFirstPositionDistanceGuess);
      canvas.rotate(-90);
      canvas.translate(-getHeight() + topPadding,edgeX);
      mEdgeGlowTop.setSize(height,height);
      if (mEdgeGlowTop.draw(canvas)) {
        invalidate();
      }
      canvas.restoreToCount(restoreCount);
    }
    if (!mEdgeGlowBottom.isFinished()) {
      final int restoreCount=canvas.save();
      final int topPadding=mListPadding.left + mGlowPaddingTop;
      final int bottomPadding=mListPadding.right + mGlowPaddingBottom;
      final int height=getHeight() - topPadding - bottomPadding;
      final int width=getWidth();
      int edgeX=Math.max(width,scrollX + mLastPositionDistanceGuess);
      canvas.rotate(90);
      canvas.translate(-topPadding,-edgeX);
      mEdgeGlowBottom.setSize(height,height);
      if (mEdgeGlowBottom.draw(canvas)) {
        invalidate();
      }
      canvas.restoreToCount(restoreCount);
    }
  }
}

@ Override public void draw ( Canvas canvas ) { super . draw ( canvas ) ; if ( mEdgeGlowTop != null ) { final int scrollX = getScrollX ( ) ; if ( ! mEdgeGlowTop . isFinished ( ) ) { final int restoreCount = canvas . save ( ) ; final int topPadding = mListPadding . top + mGlowPaddingTop ; final int bottomPadding = mListPadding . bottom + mGlowPaddingBottom ; final int height = getHeight ( ) - topPadding - bottomPadding ; int edgeX = Math . min ( 0 , scrollX + mFirstPositionDistanceGuess ) ; canvas . rotate ( - 90 ) ; canvas . translate ( - getHeight ( ) + topPadding , edgeX ) ; mEdgeGlowTop . setSize ( height , height ) ; if ( mEdgeGlowTop . draw ( canvas ) ) { invalidate ( ) ; } canvas . restoreToCount ( restoreCount ) ; } if ( ! mEdgeGlowBottom . isFinished ( ) ) { final int restoreCount = canvas . save ( ) ; final int topPadding = mListPadding . left + mGlowPaddingTop ; final int bottomPadding = mListPadding . right + mGlowPaddingBottom ; final int height = getHeight ( ) - topPadding - bottomPadding ; final int width = getWidth ( ) ; int edgeX = Math . max ( width , scrollX + mLastPositionDistanceGuess ) ; canvas . rotate ( 90 ) ; canvas . translate ( - topPadding , - edgeX ) ; mEdgeGlowBottom . setSize ( height , height ) ; if ( mEdgeGlowBottom . draw ( canvas ) ) { invalidate ( ) ; } canvas . restoreToCount ( restoreCount ) ; } } }
todo : to be implemented
