NSObject protocol doesn't include performSelectorOnMainThread: withObject: waitUntilDone: method
It appears that having your protocol conform to the NSObject protocol (@protocol MyProtocol <NSObject>
) won't help you if you need to send performSelectorOnMainThread:withObject:waitUntilDone:
messages to objects that conform to it (e.g., id
). That's because the NSObject protocol doesn't declare that method.
Instead, declare the type of your objects as NSObject conforming to your protocol like this:
NSObject *myObj;
Comments
by Zachariah Cox on 2009-08-19 13:28:25
by Masum on 2010-10-11 07:30:58