Re: Leopard-specific functionality in non–L eopard-only project

2008-06-21 Thread Mark Munz
The trick is to set the SDK to 10.5 and then in the target build settings, set:

Mac OS X Deployment Target to Mac OS X 10.4.
(under Deployment)

You'll want to set it for all your configurations: (Debug, Release, etc)

On Sat, Jun 21, 2008 at 12:51 PM, Jacob Bandes-Storch
[EMAIL PROTECTED] wrote:
 I'm working on a project (with another developer) that will target OSes
 older than 10.5, and I'd like to use the Leopard-only NSWindow method
 -setCollectionBehavior:. As far as I know, the best way to do this is to
 check for the method using -respondsToSelector:. I need to use the enum type
 NSWindowCollectionBehavior. When I try this, I get an error saying error:
 'NSWindowCollectionBehaviorCanJoinAllSpaces' undeclared (first use in this
 function) and a warning warning: 'NSWindow' may not respond to
 '-setCollectionBehavior:'. This is because I'm using the 10.4 SDK... I've
 read in some places to set the Cross-develop using target SDK setting of
 the project to 10.5, but that setting is not available in the General tab of
 the project info. Does anyone know how to do this properly without angering
 the compiler?
 ___

 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/unmarked%40gmail.com

 This email sent to [EMAIL PROTECTED]




-- 
Mark Munz
unmarked software
http://www.unmarked.com/
___

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 [EMAIL PROTECTED]


Re: Leopard-specific functionality in non–L eopard-only project

2008-06-21 Thread Jacob
Alright, thanks, but will that work if someone tries to use the project for
development who's not on 10.5?


On Sat, Jun 21, 2008 at 1:01 PM, Mark Munz [EMAIL PROTECTED] wrote:

 The trick is to set the SDK to 10.5 and then in the target build settings,
 set:

 Mac OS X Deployment Target to Mac OS X 10.4.
 (under Deployment)

 You'll want to set it for all your configurations: (Debug, Release, etc)

 On Sat, Jun 21, 2008 at 12:51 PM, Jacob Bandes-Storch
 [EMAIL PROTECTED] wrote:
  I'm working on a project (with another developer) that will target OSes
  older than 10.5, and I'd like to use the Leopard-only NSWindow method
  -setCollectionBehavior:. As far as I know, the best way to do this is to
  check for the method using -respondsToSelector:. I need to use the enum
 type
  NSWindowCollectionBehavior. When I try this, I get an error saying
 error:
  'NSWindowCollectionBehaviorCanJoinAllSpaces' undeclared (first use in
 this
  function) and a warning warning: 'NSWindow' may not respond to
  '-setCollectionBehavior:'. This is because I'm using the 10.4 SDK...
 I've
  read in some places to set the Cross-develop using target SDK setting
 of
  the project to 10.5, but that setting is not available in the General tab
 of
  the project info. Does anyone know how to do this properly without
 angering
  the compiler?

___

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 [EMAIL PROTECTED]


Re: Leopard-specific functionality in non–L eopard-only project

2008-06-21 Thread Mark Munz
If you're sharing the project between developers, they both need to be
using the same SDK (ie. 10.5 in this example). The end product will
run on both 10.4 and 10.5, but the development has to be done on a
10.5 machine (you can't develop for future OS's from an older OS).

Another option (for someone working with others on an older OS) might
be to create a Leopard-only bundle. You could then write the Leopard
only code using the SDK at 10.5, deployment on 10.4 and then load the
bundle under 10.5 and access it that way. Your 10.4 developer won't be
able to compile it, but he could still build the main project, which
would have the SDK at 10.4.

Everyone being on 10.5 is a much better option and the cost of
upgrading is easily made up for by the simpler development approach
(unless there is a specific reason why the person can't upgrade to
10.5).

Mark

On Sat, Jun 21, 2008 at 1:09 PM, Jacob [EMAIL PROTECTED] wrote:
 Alright, thanks, but will that work if someone tries to use the project for
 development who's not on 10.5?


 On Sat, Jun 21, 2008 at 1:01 PM, Mark Munz [EMAIL PROTECTED] wrote:

 The trick is to set the SDK to 10.5 and then in the target build settings,
 set:

 Mac OS X Deployment Target to Mac OS X 10.4.
 (under Deployment)

 You'll want to set it for all your configurations: (Debug, Release, etc)

 On Sat, Jun 21, 2008 at 12:51 PM, Jacob Bandes-Storch
 [EMAIL PROTECTED] wrote:
  I'm working on a project (with another developer) that will target OSes
  older than 10.5, and I'd like to use the Leopard-only NSWindow method
  -setCollectionBehavior:. As far as I know, the best way to do this is to
  check for the method using -respondsToSelector:. I need to use the enum
 type
  NSWindowCollectionBehavior. When I try this, I get an error saying
 error:
  'NSWindowCollectionBehaviorCanJoinAllSpaces' undeclared (first use in
 this
  function) and a warning warning: 'NSWindow' may not respond to
  '-setCollectionBehavior:'. This is because I'm using the 10.4 SDK...
 I've
  read in some places to set the Cross-develop using target SDK setting
 of
  the project to 10.5, but that setting is not available in the General tab
 of
  the project info. Does anyone know how to do this properly without
 angering
  the compiler?

 ___

 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/unmarked%40gmail.com

 This email sent to [EMAIL PROTECTED]




-- 
Mark Munz
unmarked software
http://www.unmarked.com/
___

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 [EMAIL PROTECTED]


Re: Leopard-specific functionality in non–L eopard-only project

2008-06-21 Thread Mike Abdullah
If you're desperate to stick with the 10.4 SDK, I'd suggest the best  
approach is just to create your own header that mimics the method. So  
you'd end up with something like:


@interface NSWindow (LeopardOnlyMethods)
- (void)setCollectionBehavior:(int)behavior;
@end

...
[window setCollectionBehavior:1];



Mike.

On 21 Jun 2008, at 20:51, Jacob Bandes-Storch wrote:

I'm working on a project (with another developer) that will target  
OSes older than 10.5, and I'd like to use the Leopard-only NSWindow  
method -setCollectionBehavior:. As far as I know, the best way to do  
this is to check for the method using -respondsToSelector:. I need  
to use the enum type NSWindowCollectionBehavior. When I try this, I  
get an error saying error:  
'NSWindowCollectionBehaviorCanJoinAllSpaces' undeclared (first use  
in this function) and a warning warning: 'NSWindow' may not  
respond to '-setCollectionBehavior:'. This is because I'm using the  
10.4 SDK... I've read in some places to set the Cross-develop using  
target SDK setting of the project to 10.5, but that setting is not  
available in the General tab of the project info. Does anyone know  
how to do this properly without angering the compiler?

___

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/cocoadev%40mikeabdullah.net

This email sent to [EMAIL PROTECTED]


___

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 [EMAIL PROTECTED]