Re: cocoa sheets
Re: cocoa sheets
- Subject: Re: cocoa sheets
- From: Donald Brown <email@hidden>
- Date: Fri, 09 Nov 2001 15:25:57 -0600
on 11/8/2001 6:05 PM, Robert Goldsmith at email@hidden
wrote:
>
Hi all :)
>
>
I know this has prob been answered before but I can't find the answer
>
anywhere:
>
>
what is the correct way to close a sheet?
Here's how I'm doing it for a Find sheet I'm using:
I've linked the target of my buttons to two actions for my document,
doFindOK and doFindCancel, and the sheet is an outlet called mFindWindow.
In my Find routine, after getting things set up, I call begin sheet with no
modal parameters, like this:
[NSApp beginSheet:mFindWindow
modalForWindow:[self window]
modalDelegate:nil
didEndSelector:nil
contextInfo:nil];
(self window is a class that returns the NSWindow* of my main window)
The doFindCancel action does the following:
[NSApp endSheet:mFindWindow];
[mFindWindow orderOut:self];
DoFindOK operates on the find, and then does the same stuff.
Does that help?
Donald
--
Donald Brown
email@hidden
http://www.eamontales.com
We have met the enemy and he is us - Pogo
References: | |
| >cocoa sheets (From: Robert Goldsmith <email@hidden>) |