user32: When destroying a window, preserve the first WM_QUIT message that was posted to it.
This commit is contained in:
parent
30f2c6610d
commit
ff8f6e8662
|
@ -10241,7 +10241,7 @@ static void test_quit_message(void)
|
|||
add_message(&rmsg);
|
||||
DispatchMessage(&msg);
|
||||
}
|
||||
ok_sequence(WmStopQuitSeq, "WmStopQuitSeq", TRUE);
|
||||
ok_sequence(WmStopQuitSeq, "WmStopQuitSeq", FALSE);
|
||||
}
|
||||
|
||||
static const struct message WmMouseHoverSeq[] = {
|
||||
|
|
|
@ -1918,7 +1918,15 @@ void queue_cleanup_window( struct thread *thread, user_handle_t win )
|
|||
LIST_FOR_EACH_SAFE( ptr, next, &queue->msg_list[i] )
|
||||
{
|
||||
struct message *msg = LIST_ENTRY( ptr, struct message, entry );
|
||||
if (msg->win == win) remove_queue_message( queue, msg, i );
|
||||
if (msg->win == win)
|
||||
{
|
||||
if (msg->msg == WM_QUIT && !queue->quit_message)
|
||||
{
|
||||
queue->quit_message = 1;
|
||||
queue->exit_code = msg->wparam;
|
||||
}
|
||||
remove_queue_message( queue, msg, i );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue