On Tue, Sep 8, 2009 at 3:25 PM, Brent Gulanowski<bgulanow...@gmail.com> wrote: > For classes, you can check whether NSClassFromString(@"Classname") returns a > class.
This might return incompatible private versions of some classes. For example, NSClassFromString(@"QLPreviewPanel") will return a class with a very different API on 10.5 than it does on 10.6. > For selectors, you can check whether NSSelectorFromString(@"selector") > returns a selector. This is untrue. NSSelectorFromString always returns a selector. > Usually that's enough. In fact, if you pick a representative class that was > introduced in the OS release of your choice, you can use that as a short cut > to check for the OS version. Or you can check the version major and minor > values using Gestalt for accurate version info: Do not use NSClassFromString to check for OS versions. There is absolutely no guarantee it will work. --Kyle Sluder _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com