Re: The best way to call Cocoa methods not implemented in previous versions of the SDK?
Re: The best way to call Cocoa methods not implemented in previous versions of the SDK?
- Subject: Re: The best way to call Cocoa methods not implemented in previous versions of the SDK?
- From: Jens Alfke <email@hidden>
- Date: Tue, 06 Sep 2011 09:56:04 -0700
On Sep 6, 2011, at 3:42 AM, Mike Abdullah wrote:
> performSelector really isn't cumbersome at all:
> [window performSelector:@selector(setRestorationClass:) withObject:someClass];
Not in this case, but it doesn’t work for methods that take non-object parameters, or more than two parameters.
The approach I prefer is to declare the method in a category:
@interface NSWindow (StuffAppleAddedIn10_7)
- (void) setRestorationClass:(Class)aClass;
@end
—Jens_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden