Graham Cox (graham....@bigpond.com) on 2010-03-02 20:14 said:

>I need to write a package file that is not listed as one of my document
>types. How do I ensure that this will be seen as a package in the
>Finder? It looks to me as though some new flags were added to NSURL to
>cover this but the code needs to work on 10.5 or later.

If you use the MoreFilesX sample code, you can just do this:

 FSChangeFinderFlags (&bundleFSRef, true, kHasBundle);

(It's always a good idea to set the bundle bit on all bundle-type
documents because if your application is not on any of your disks, the
Finder will show a folder. Ever install a fresh system (with no Xcode)
and navigate to a folder with an .xcodeproj?  It will appear as a folder
because Xcode doesn't set the bundle bit.)

Sean


_______________________________________________

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