As of 10.4, document role claims may reference document type
information via a UTI instead of by listing extensions and OSTypes
explicitly.
So which <key> do you use inside a CFBundleDocumentTypes array to
make a claim via UTI? Is it LSItemContentTypes?
Correct. On 10.4.x, when LSItemContentTypes is present, then the
CFBundleTypeExtensions, CFBundleTypeOSTypes and CFBundleTypeMIMETypes
keys are ignored. You will still want to use CFBundleTypeName to
provide a localizable kind string, CFBundleTypeRole to specify the
document role, and CFBundleTypeIconFile to specify an application-
specific document icon. The value of the LSItemContentTypes key is
an array of uniform type identifiers.
The Launch Services documentation is in the process of being updated
to cover this feature. For now, there is at least this Spotlight-
specific example of using LSItemContentTypes:
Also, if we want to support both MacOS X 10.3 and 10.4, should we
keep the CFBundleTypeOSTypes and CFBundleTypeExtensions entries
specified within the CFBundleDocumentTypes section of the plist
also. Seems redundant since this info is in the
UTExportedTypeDeclarations, but maybe it's necessary? Or is the
claim using the UTI enough, even for 10.3?
You must keep the CFBundleTypeOSTypes and CFBundleTypeExtensions
entries in order to remain compatible with Mac OS X 10.3 and earlier.
We tried to keep it as simple as possible: On 10.3 and earlier,
CFBundleTypeOSTypes and CFBundleTypeExtensions are required. On 10.4
and later, you may use LSItemContentTypes, and when you do, the
system ignores the legacy keys (CFBundleTypeExtensions,
CFBundleTypeOSTypes and CFBundleTypeMIMETypes).
-Chris
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Carbon-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/carbon-dev/email@hidden