modocache / MDCSwipeToChoose

Swipe to "like" or "dislike" any view, just like Tinder.app. Build a flashcard app, a photo viewer, and more, in minutes, not hours!
MIT License
2.55k stars 422 forks source link

onPan animation based on pan distance #113

Open acegreen opened 8 years ago

acegreen commented 8 years ago

Hi,

I would like to adjust the view based on the view "infront" of it. Basically using the thresholdRatio. I want to grow the back view to the size of the front view as you pan. I am able to move it in X or Y but can't seem to crack the logic

Inputs: frontView.frame backView.frame thresholdRatio