Broken implementation of beginModalSessionForWindow vs. runModalForWindow
Broken implementation of beginModalSessionForWindow vs. runModalForWindow
- Subject: Broken implementation of beginModalSessionForWindow vs. runModalForWindow
- From: Steven Kramer <email@hidden>
- Date: Wed, 22 Sep 2004 12:26:13 +0200
Hi all,
Has anyone else noticed that you can't continue a modal loop after
running a secondary modal loop if you use runModalSession
NSModalSession session;
session = [[NSApplication sharedApplication]
beginModalSessionForWindow: firstModalPanel];
int modalCode;
do {
modalCode = [NSApp runModalSession: session];
} while (modalCode == NSRunContinuesResponse);
[NSApp endModalSession: session];
instead of
[NSApp runModalForWindow: firstModalPanel];
The documentation states this should be (near)identical behavior.
Apparently, this is not so. And has anyone found a better work-around
than simply ignoring the stop code after the second modal session ends?
Regards,
Steven
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden