[swift-evolution] Extensions to add observers
Cody Weaver
codyleeweaver at gmail.com
Wed Apr 20 18:08:30 CDT 2016
This is my first time posting anything in the evolution forum or the users
forum, so I apologize if this isn't how we are supposed to do things.
PROPOSAL
My idea is to add a property observer in an extension.
MOTIVATION
This would make it so we can get rid of selectors. It's my understanding
the selectors are "Objective-C".
PROPOSED SOLUTION
extension UIGestureRecognizer {
self.state {
didSet {
self.handleStateChange()
}
}
}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20160420/01949f2d/attachment.html>
More information about the swift-evolution
mailing list