Re: Getting HFS file type of an application
Re: Getting HFS file type of an application
- Subject: Re: Getting HFS file type of an application
- From: Finlay Dobbie <email@hidden>
- Date: Sun, 17 Jul 2005 20:02:18 +0100
On 7/17/05, Steve Palmer <email@hidden> wrote:
> Given a path to an application bundle in the /Applications folder,
> how do I get the HFS file type of the application. NSHFSTypeOfFile
> requires that the path is pointing to an actual Mach executable so I
> would need to drill down into Contents\MacOS to find the actual
> executable. Is there an equivalent function that will work if the
> path is pointing to the root of the bundle (e.g. Mail.app)?
The HFS file type of an application should always be "APPL". Also,
note that going down to the actual executable and getting the type of
that probably won't work, since the type/creator applies to the bundle
not the executable.
To get this sort of information, you should be using Launch Services
anyway. See <http://developer.apple.com/documentation/Carbon/Reference/LaunchServicesReference/LSRReference/chapter_1.2_section_4.html>.
-- Finlay
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden