Thanks Shawn and Steve. I thought it might have to do with the web
archive uti if not the uti constants in general. I'm already weak
linking my app and checking for 10.4 before calling other methods, so
I should be able to slide this in without too much difficulty.
-Phil
Jan 3, 2006, at 11:41 PM, Steve Christensen wrote:
Jan 3, 2006, at 1:48 PM, Philip Dow wrote:
>
>According to the "Introduction to Uniform Type Identifiers
>" document: "Support for uniform type identifiers is
>available in Mac S X v10.3 and later."
>>
>According to the "System-Declared Uniform Type Identifiers:
>document: Table 3-1 lists the uniform type identifiers that are
>declared by the system as of Mac S X v10.4.
>>
>I recently upgraded a file importing mechanism in my program to
>use the Uniform Type Identifiers scheme and its associated
>methods. This works beautifully in 10.4, but users running 10.3.9
>are encountering crashes when importing files. I believe I have
>tracked it down to the UTI references.
>>
>According to bit of documentation, UTIs should work in 10.3.9, but
>according to another bit of documentation, the constants used by
>the UTI implementation such as kUTTypeText or kUTTypeWebArchive
>are available as of 10.4. What's going on here? Am I allowed to
>use the UTI scheme in 10.3.9 as long as I hardcode the UTI
>definitions, ie @"com.apple.webarchive" for kUTTypeWebArchive. The
>crash log does not offer much in the way of usefulness when the
>app goes down during an import, but if I had to guess, it would be
>because I'm referencing symbols that are only included in 10.4 and
>above.
>>
>Can anyone confirm that hypothesis?
>
I seem to recall that there was a recent posting, either here or on
the Carbon list, about this topic. I believe the replier said that
you would have to provide your own UTI strings for any 10.4+ UTI
strings if you're running on a pre-10.4 system. You could certainly
define a class with methods that do the right thing for both cases
so that callers don't have to know the gory details, something like:
+ (NSString*) getUTTypeWebArchive
{
#if MACS_X_VERSIN_MIN_REQUIRED < MACS_X_VERSIN_10_4
if (kUTTypeWebArchive == NULL)
return @"com.apple.webarchive";
#endif
return (NSString*) kUTTypeWebArchive;
}
--
steve
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (Cocoa-dev (AT) lists (DOT) apple.com)
Help/Unsubscribe/Update your Subscription:
%40phildow.net
This email sent to dev (AT) phildow (DOT) net
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (Cocoa-dev (AT) lists (DOT) apple.com)
Help/Unsubscribe/Update your Subscription:
%40developershed.com
This email sent to bsdarchive (AT) developershed (DOT) com