取消调用事件的连接

时间:2015-09-28 17:58:12

标签: ios swift

如何取消某个功能,以便它不被调用?

//Wire an event
myScrollView.delegate = self
... do something
// How can I unwire it so the scrollview functions dont get called? 

1 个答案:

答案 0 :(得分:0)

如果您不再希望调用任何delegate方法,只需将nil属性设置为delegate