http://bugs.winehq.org/show_bug.cgi?id=11026
--- Comment #4 from Lei Zhang thestig@google.com 2008-01-04 15:57:08 --- (In reply to comment #3)
(In reply to comment #0)
On KDE, both the main window and the keywords window look like they are active. If you start typing, the letters go into the keywords window, but if you press Alt + F4, the main window closes. (and the tool window with it)
The above looks like a KDE bug. On Alt+F4 it should send a WM_DELETE_WINDOW event to a window with keyboard focus.
I looked at the +event output while running the test program:
with the mouse outside the tool window:
trace:event:process_events processed 1 events trace:event:process_events FocusOut for hwnd/window 0x10024/3c00001 trace:event:EVENT_FocusOut win 0x10024 xwin 3c00001 detail=NotifyAncestor trace:event:process_events FocusIn for hwnd/window 0x10024/3c00001 trace:event:EVENT_FocusIn win 0x10024 xwin 3c00001 detail=NotifyAncestor trace:event:process_events KeymapNotify for hwnd/window (nil)/0
with the mouse inside the tool window:
trace:event:process_events processed 1 events trace:event:process_events FocusOut for hwnd/window 0x10024/3c00001 trace:event:EVENT_FocusOut win 0x10024 xwin 3c00001 detail=NotifyAncestor trace:event:process_events FocusIn for hwnd/window 0x10028/3c00007 trace:event:EVENT_FocusIn win 0x10028 xwin 3c00007 detail=NotifyPointer trace:event:process_events KeymapNotify for hwnd/window (nil)/0 trace:event:process_events FocusOut for hwnd/window 0x10028/3c00007 trace:event:EVENT_FocusOut win 0x10028 xwin 3c00007 detail=NotifyPointer trace:event:process_events FocusIn for hwnd/window 0x10024/3c00001 trace:event:EVENT_FocusIn win 0x10024 xwin 3c00001 detail=NotifyAncestor trace:event:process_events KeymapNotify for hwnd/window (nil)/0
win 0x10024 is the parent window, and 0x10028 is the tool window. In either case, the parent window has focus, so it's correctly receiving the WM_DELETE_WINDOW event.