Re: Adding Resource Bundles
Re: Adding Resource Bundles
- Subject: Re: Adding Resource Bundles
- From: "Sean McBride" <email@hidden>
- Date: Fri, 26 Aug 2005 10:09:04 -0400
- Organization: Rogue Research
On 2005-08-25 22:08, Achal Oza said:
>#ifdef LINUX
>loadTexture("images/image.bmp");
>#else
>loadTexture("MyApp.app/Contents/Resources/image.bmp");
>#endif
This will break if the user renames MyApp.app, which users can easily do
in the Finder.
>I'm just curios now if there's a cleaner way of doing this? Perhaps
>some preprocessor variable for "MyApp.app/Contents/Resources"?
You can use NSBundle or CFBundle APIs to get that path. ex: NSBundle's -
mainBundle
--
____________________________________________________________
Sean McBride, B. Eng email@hidden
Rogue Research www.rogue-research.com
Mac Software Developer Montréal, Québec, Canada
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden