On 14.11.2011, at 19:20, Quincey Morris wrote:

> Don't follow the advice to define NSWindowCollectionBehaviorFullScreenPrimary 
> yourself. It's really, really dangerous to replicate a fragment of one SDK in 
> a build against an earlier SDK. What if the value changes in a later 10.7.x 
> SDK, or if the value is invalidated in some way you can't foresee?

If that value changed in a later SDK, it would break binary compatibility. 
While I strongly suggest against replicating SDK code in your own code for the 
reason you're giving, it does not apply in this case.

Any application compiled today will have a constant number in place of 
NSWindowCollectionBehaviorFullScreenPrimary. If the OS at some point changes 
the meaning of that number, it will break all applications compiled before that 
date.

> There's only one safe way to use features from a later SDK: use the later SDK 
> as your base SDK, and set your deployment target to the earlier system 
> version, adding run-time checks to ensure that you don't use the later SDK's 
> features on an earlier system.

That is a practice I consider just as dangerous. It is very easy to end up 
using APIs that are newer than your minimum supported version and forgetting to 
add the run-time check. Mac OS will allow you to run that application on lower 
OS versions, but at best it will not behave as intended, but it is also quite 
likely to crash.

-Stefan_______________________________________________

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

Reply via email to