Re: Extension Hiding in NSSavePanel : Not Toggling properly?
Re: Extension Hiding in NSSavePanel : Not Toggling properly?
- Subject: Re: Extension Hiding in NSSavePanel : Not Toggling properly?
- From: Dan Wood <email@hidden>
- Date: Tue, 25 Sep 2001 15:42:49 -0700
Thanks Ali. For those who are interested, it turns out that I was
neglecting to use NSSavePanel setRequiredFileType:(NSString
*)extension
to indicate what the extension is. With that, things work just as
expected.
On Tuesday, September 25, 2001, at 02:30 PM, Ali Ozer wrote:
>
> I'm trying to do an NSSavePanel and handle the hidden extension
>
> properly. It's not quite working right. In other
>
> hidden-extension-savvy applications, the extension disappears and
>
> reappears when I toggle the checkbox in the Save Panel. Is this
>
> something I have to do manually through some hackery?
>
>
TextEdit is an example of how this can be done --- at least for
>
the RTF/RTFD cases. (The plain text case is a bit more tricky in
>
TextEdit, and there is at least one issue.)
>
>
Assuming you tell NSSavePanel what the required extension is, you
>
don't have to do anything yourself while the panel is being
>
run --- the filename you get back should always have the
>
extension; you just set the hidden extension bit when saving the
>
file.
>
>
Ali
>
>
>
--
Dan Wood
email@hidden
http://www.karelia.com/
http://www.bikealameda.org/
Mac OS X Developer: Online Resume:
http://www.karelia.com/resume.html
"We have met the enemy and he is us" -- Walter Kelly (Pogo),
perhaps predicting the World Trade Center tragedy and America's
foreign policies and our sorry excuse for airline security...