NSBeginAlertSheet Crashing
NSBeginAlertSheet Crashing
- Subject: NSBeginAlertSheet Crashing
- From: Michael Wood <email@hidden>
- Date: Thu, 29 May 2003 22:11:15 -0700
- Organization: Retrix Hosting http://retrix.com/
Hello, I am writing an application that is on a timer, when the timer
is complete it notifies the user with a bouncing dock icon and a sheet
with a message.
The bouncing dock icon works as expected when the application is not in
focus, or hidden.
[NSApp requestUserAttention:NSCriticalRequest];
When I use the sheet it has mixed results. When the application is in
focus the sheet pops down like it should. When the application is not
in focus (there are application behind it like when you click on the
finder - out of focus yet still in the foreground) the window
disappears behind all the applications the sheet comes down and the
icon bounces as expected. The third problem which causes a crash is
when the application is hidden. When the timer expires it unhides the
window and the sheet is no longer attached to the window. When I click
the 'OK' button the application crashes. Below is the call I use for my
sheet.
NSBeginAlertSheet(@"Your laundry is ready!", @"OK", nil, nil, window,
self, @selector(holySheet:returnCode:contextInfo:), nil, nil,
@"Everything should be dry now, enjoy your folding.");
Any help resolving this would be greatly appreciated.
Cheers,
Mike.
_______________________________________________
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.