diff -r 3b1da2848fc7 -r d3bac044e0f0 src/gui/kernel/qeventdispatcher_mac.mm --- a/src/gui/kernel/qeventdispatcher_mac.mm Fri Feb 19 23:40:16 2010 +0200 +++ b/src/gui/kernel/qeventdispatcher_mac.mm Fri Mar 12 15:46:37 2010 +0200 @@ -569,7 +569,7 @@ // in cocoa. [NSApp run] should be called at least once for any cocoa app. if (NSModalSession session = d->currentModalSession()) { QBoolBlocker execGuard(d->currentExecIsNSAppRun, false); - while (!d->interrupt && [NSApp runModalSession:session] == NSRunContinuesResponse) + while ([NSApp runModalSession:session] == NSRunContinuesResponse && !d->interrupt) qt_mac_waitForMoreModalSessionEvents(); if (!d->interrupt && session == d->currentModalSessionCached) { // INVARIANT: Someone called e.g. [NSApp stopModal:] from outside the event