Last active
October 26, 2015 22:03
-
-
Save antonkartashov/3df219116d2b90b68d55 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pos = [] | |
touchDown = false | |
card.on Events.TouchStart, (e) -> | |
touchDown = true | |
pos.x = Events.touchEvent(e).clientX | |
pos.y = Events.touchEvent(e).clientY | |
card.on Events.TouchEnd, (e) -> | |
touchDown = false | |
if pos.x is Events.touchEvent(e).clientX and | |
pos.y is Events.touchEvent(e).clientY | |
card.animate properties: { y: 0 }, time: .05 | |
card.on Events.DragEnd, -> | |
touchDown = false |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment