modal alert sheets
modal alert sheets
- Subject: modal alert sheets
- From: Robert Vasvari <email@hidden>
- Date: Mon, 12 Aug 2002 12:43:43 -0700 (PDT)
Howdy,
I am trying to get an alert sheet that is like the
panel of NSGetAlertPanel, but attached to a window as
a sheet. NSGetAlertPanel has a convenient modal API,
and it would be convenient to use where it is
difficult to replace it with non modal alert sheets. I
did this in 10.1.x like this:
NSWindow
*alertPanel=NSGetAlertPanel(aTitle,message,@"OK",nil,nil);
[NSApp beginSheet:alertPanel
modalForWindow:aWindow modalDelegate:nil
didEndSelector:nil
contextInfo:nil];
retCode=[NSApp runModalForWindow:alertPanel];
[alertPanel orderOut:self];
[NSApp endSheet:alertPanel];
NSReleaseAlertPanel(alertPanel);
This no longer works correctly on the Jaguar previews.
I do get the sheet with the buttons, but each button
must be pressed twice in order for [NSApp
stopModalWithCode:] to be called. This might just be a
Jag bug, but is there an easier way to get this modal
alert sheet up?
R
HotJobs - Search Thousands of New Jobs
http://www.hotjobs.com
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.