Created
August 25, 2016 05:54
-
-
Save ukitaka/54972f9c44d5054d1b7856fc4c9f75f6 to your computer and use it in GitHub Desktop.
DelegateProxy
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class MyTableViewDelegateProxy: RxTableViewDelegateProxy { | |
func tableView(tableView: UITableView, editActionsForRowAtIndexPath indexPath: NSIndexPath) -> [UITableViewRowAction]? { | |
return [] | |
} | |
} | |
extension UITableView { | |
override public func rx_createDelegateProxy() -> RxScrollViewDelegateProxy { | |
return MyTableViewDelegateProxy(parentObject: self) | |
} | |
override public var rx_delegate: DelegateProxy { | |
return MyTableViewDelegateProxy.proxyForObject(self) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment