Bug 539164 – Windows' System Menu blocks main loop
2008-07-01 Cody Russell <bratsche@gnome.org> Bug 539164 – Windows' System Menu blocks main loop * gdk/win32/gdkevents-win32.c: Use a modal timer proc in between receiving WM_ENTERMENULOOP and WM_EXITMENULOOP and pump the GLib mainloop from there. svn path=/trunk/; revision=20726
This commit is contained in:
committed by
Cody Russell
parent
688470400b
commit
0d0f9a7fc1
@ -138,7 +138,7 @@ static HKL latin_locale = NULL;
|
||||
#endif
|
||||
|
||||
static gboolean in_ime_composition = FALSE;
|
||||
static UINT resize_timer;
|
||||
static UINT modal_timer;
|
||||
|
||||
static int debug_indent = 0;
|
||||
|
||||
@ -2030,7 +2030,7 @@ handle_stuff_while_moving_or_resizing (void)
|
||||
}
|
||||
|
||||
static VOID CALLBACK
|
||||
resize_timer_proc (HWND hwnd,
|
||||
modal_timer_proc (HWND hwnd,
|
||||
UINT msg,
|
||||
UINT id,
|
||||
DWORD time)
|
||||
@ -2972,12 +2972,22 @@ gdk_event_translate (MSG *msg,
|
||||
|
||||
case WM_ENTERSIZEMOVE:
|
||||
_sizemove_in_progress = TRUE;
|
||||
resize_timer = SetTimer (NULL, 0, 20, resize_timer_proc);
|
||||
modal_timer = SetTimer (NULL, 0, 20, modal_timer_proc);
|
||||
break;
|
||||
|
||||
case WM_EXITSIZEMOVE:
|
||||
_sizemove_in_progress = FALSE;
|
||||
KillTimer (NULL, resize_timer);
|
||||
KillTimer (NULL, modal_timer);
|
||||
break;
|
||||
|
||||
case WM_ENTERMENULOOP:
|
||||
_sizemove_in_progress = TRUE;
|
||||
modal_timer = SetTimer (NULL, 0, 20, modal_timer_proc);
|
||||
break;
|
||||
|
||||
case WM_EXITMENULOOP:
|
||||
_sizemove_in_progress = FALSE;
|
||||
KillTimer (NULL, modal_timer);
|
||||
break;
|
||||
|
||||
case WM_WINDOWPOSCHANGED :
|
||||
|
||||
Reference in New Issue
Block a user