The House Cup: An Imagineering Competition - Discussion Thread

Voxel

President of Progress City
We can switch

I'm writing a mini-thesis
Perfect, I can handle that: Can you handle this:
Code:
let tap = UITapGestureRecognizer(target: self, action: "doubleTap")
        tap.numberOfTapsRequired = 2
        useful.addGestureRecognizer(tap)
       
        swipeableView.didStart = {view, location in self.removeTop()}
        swipeableView.onlySwipeTopCard = true
   
        //Get Gesture dection for deleting previous
        let swipeRight = UISwipeGestureRecognizer(target: self, action: "removeTop")
        swipeRight.direction = UISwipeGestureRecognizerDirection.Right
        self.view.addGestureRecognizer(swipeRight)
 

spacemt354

Chili's
Original Poster
Perfect, I can handle that: Can you handle this:
Code:
let tap = UITapGestureRecognizer(target: self, action: "doubleTap")
        tap.numberOfTapsRequired = 2
        useful.addGestureRecognizer(tap)
      
        swipeableView.didStart = {view, location in self.removeTop()}
        swipeableView.onlySwipeTopCard = true
  
        //Get Gesture dection for deleting previous
        let swipeRight = UISwipeGestureRecognizer(target: self, action: "removeTop")
        swipeRight.direction = UISwipeGestureRecognizerDirection.Right
        self.view.addGestureRecognizer(swipeRight)
Absolutely I'll get right on that.
 

Voxel

President of Progress City
Basically this is adding a double tap, so if the user taps the screen twice it calls the function doubleTap

let tap = UITapGestureRecognizer(target: self, action: "doubleTap")
tap.numberOfTapsRequired = 2
useful.addGestureRecognizer(tap)


Not really sure what is going on here.. It's chaos and belongs to someone else source code.
swipeableView.didStart = {view, location in self.removeTop()}
swipeableView.onlySwipeTopCard = true

This adds a new function to the gesture of swiping the screen. I'm gonna recognize only swiping right and finally I'm adding it to the subsystem that "listen" for gestures on the screen/
let swipeRight = UISwipeGestureRecognizer(target: self, action: "removeTop")
swipeRight.direction = UISwipeGestureRecognizerDirection.Right
self.view.addGestureRecognizer(swipeRight)
 

Register on WDWMAGIC. This sidebar will go away, and you'll see fewer ads.

Back
Top Bottom