Skip to content
Permalink
Browse files

Screen edge swipes fixed

  • Loading branch information
Koen Bok
Koen Bok committed Feb 4, 2016
1 parent 9876ddd commit e57ec36117dd5b8b93d8b9d80e3072bc761a1055
Showing with 21 additions and 22 deletions.
  1. +0 −22 framer/Layer.coffee
  2. +21 −0 framer/Screen.coffee
@@ -1072,28 +1072,6 @@ class exports.Layer extends BaseClass
onSwipeRightStart:(cb) -> @on(Events.SwipeRightStart, cb)
onSwipeRightEnd:(cb) -> @on(Events.SwipeRightEnd, cb)

# Edge Swipe

onEdgeSwipe:(cb) -> @on(Events.EdgeSwipe, cb)
onEdgeSwipeStart:(cb) -> @on(Events.EdgeSwipeStart, cb)
onEdgeSwipeEnd:(cb) -> @on(Events.EdgeSwipeEnd, cb)

onEdgeSwipeTop:(cb) -> @on(Events.EdgeSwipeTop, cb)
onEdgeSwipeTopStart:(cb) -> @on(Events.EdgeSwipeTopStart, cb)
onEdgeSwipeTopEnd:(cb) -> @on(Events.EdgeSwipeTopEnd, cb)

onEdgeSwipeRight:(cb) -> @on(Events.EdgeSwipeRight, cb)
onEdgeSwipeRightStart:(cb) -> @on(Events.EdgeSwipeRightStart, cb)
onEdgeSwipeRightEnd:(cb) -> @on(Events.EdgeSwipeRightEnd, cb)

onEdgeSwipeBottom:(cb) -> @on(Events.EdgeSwipeBottom, cb)
onEdgeSwipeBottomStart:(cb) -> @on(Events.EdgeSwipeBottomStart, cb)
onEdgeSwipeBottomEnd:(cb) -> @on(Events.EdgeSwipeBottomEnd, cb)

onEdgeSwipeLeft:(cb) -> @on(Events.EdgeSwipeLeft, cb)
onEdgeSwipeLeftStart:(cb) -> @on(Events.EdgeSwipeLeftStart, cb)
onEdgeSwipeLeftEnd:(cb) -> @on(Events.EdgeSwipeLeftEnd, cb)

# Pan
onPan:(cb) -> @on(Events.Pan, cb)
onPanStart:(cb) -> @on(Events.PanStart, cb)
@@ -47,6 +47,27 @@ class ScreenClass extends BaseClass

return "<Screen #{round(@width)}x#{round(@height)}>"

# Edge Swipe

onEdgeSwipe:(cb) -> @on(Events.EdgeSwipe, cb)
onEdgeSwipeStart:(cb) -> @on(Events.EdgeSwipeStart, cb)
onEdgeSwipeEnd:(cb) -> @on(Events.EdgeSwipeEnd, cb)

onEdgeSwipeTop:(cb) -> @on(Events.EdgeSwipeTop, cb)
onEdgeSwipeTopStart:(cb) -> @on(Events.EdgeSwipeTopStart, cb)
onEdgeSwipeTopEnd:(cb) -> @on(Events.EdgeSwipeTopEnd, cb)

onEdgeSwipeRight:(cb) -> @on(Events.EdgeSwipeRight, cb)
onEdgeSwipeRightStart:(cb) -> @on(Events.EdgeSwipeRightStart, cb)
onEdgeSwipeRightEnd:(cb) -> @on(Events.EdgeSwipeRightEnd, cb)

onEdgeSwipeBottom:(cb) -> @on(Events.EdgeSwipeBottom, cb)
onEdgeSwipeBottomStart:(cb) -> @on(Events.EdgeSwipeBottomStart, cb)
onEdgeSwipeBottomEnd:(cb) -> @on(Events.EdgeSwipeBottomEnd, cb)

onEdgeSwipeLeft:(cb) -> @on(Events.EdgeSwipeLeft, cb)
onEdgeSwipeLeftStart:(cb) -> @on(Events.EdgeSwipeLeftStart, cb)
onEdgeSwipeLeftEnd:(cb) -> @on(Events.EdgeSwipeLeftEnd, cb)

# We use this as a singleton
exports.Screen = new ScreenClass

0 comments on commit e57ec36

Please sign in to comment.
You can’t perform that action at this time.