Skip to content

Releases: djnivek/SwiftyGestureRecognizer

Generics works fine

06 Aug 15:32
Compare
Choose a tag to compare
Generics works fine Pre-release
Pre-release

The previous generics support was unstable. This version works fine.

New way to install a recognizer into a view.

GestureRecognizer(for: label).pressed { (label, _) in
    label.textColor = .red
}

Generics Support

03 Apr 08:47
Compare
Choose a tag to compare
Generics Support Pre-release
Pre-release

Generics support added

GestureRecognizer.install(contactLabel).pressed { (element, recognizer) in
    (element as! UILabel).textColor = .red
}

Can now be implemented like this:

GestureRecognizer.install(contactLabel).pressed { (label, recognizer) in
    label.textColor = .red
}