hudomju / android-swipe-to-dismiss-undo

Android swipe-to-dismiss-undo library and sample code
MIT License
239 stars 84 forks source link

Replace fade out animation #14

Open MaxBleggi opened 9 years ago

MaxBleggi commented 9 years ago

I would like to replace the fading out animation with one like in gmail where it just is swiped and the opacity doesn't change. Does anyone know how to do this or where the fading animation is. I think it's in SwipeToDismissTouchListener.java. Is there a way to override the default animation in it?

leijdekkers commented 9 years ago

Comment out this line in the SwipeToDismissTouchListener.java file.

 //  mRowContainer.getCurrentSwipingView().setAlpha(Math.max(0f, Math.min(1f, 1f - 2f * Math.abs(deltaX) / mViewWidth)));