Applied patch from dec 10th. It does not solve the problem that the About dialog drops behind the Sudoku window though...

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6964 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Matthias Melcher
2009-12-12 18:18:54 +00:00
parent 4880ebc521
commit 3f689a7d2f
+13
View File
@@ -659,6 +659,19 @@ static double do_queued_events( double time = 0.0 )
}
}
}
//necessary so that after closing a non-FLTK window (e.g., Fl_Native_File_Chooser)
//the front window turns key again
if([NSApp keyWindow] == nil) {
Fl_Window *w = Fl::first_window();
if (w) {
NSWindow *cw = (NSWindow*)Fl_X::i(w)->xid;
if([cw isVisible] && ![cw isMiniaturized] && ([cw styleMask] & NSTitledWindowMask) ) {
if(![cw isKeyWindow]) {//always make Fl::first_window() the key window
[cw makeKeyWindow];
}
}
}
}
NSEvent *event = [NSApp nextEventMatchingMask:NSAnyEventMask
untilDate:[NSDate dateWithTimeIntervalSinceNow:time]
inMode:NSDefaultRunLoopMode dequeue:YES];