ios - How to change the swipe direction of UISwipegestureRecognizer using @IBAction -
for reason won't work, doing wrong here?
the second option is: creating
uiswipegesturerecognizer()
then setting using
.direction = .up
and adding using
addgesturerecognizer()
works. want using code below.
class faceviewcontroller : uiviewcontroller { @iboutlet weak var labelvar: uilabel! // mark: gestures @ibaction func swiping(sender: uiswipegesturerecognizer) { sender.direction = .up self.test() } func test() { labelvar!.text = "up" } }
Comments
Post a Comment