summaryrefslogtreecommitdiff
path: root/gdk/win32
diff options
context:
space:
mode:
authorAlexander Larsson <alexl@redhat.com>2011-10-25 15:34:22 +0200
committerAlexander Larsson <alexl@redhat.com>2011-11-10 17:40:59 +0100
commit429bd4e5d56ae7e6f7f7139774d623ff629ef8b2 (patch)
treec0f1f5a09746864203cfd5636fceb1f60602054a /gdk/win32
parentad374a595cf683bc1f07e16c444a44b399b5dca3 (diff)
downloadgtk+-429bd4e5d56ae7e6f7f7139774d623ff629ef8b2.tar.gz
win32: Fix missed resize exit message
When you start a window resize or move via the window menu and don't actually change anything we're not getting an exitsizemove. In order to work around this we also look for WM_CAPTURECHANGED.
Diffstat (limited to 'gdk/win32')
-rw-r--r--gdk/win32/gdkevents-win32.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/gdk/win32/gdkevents-win32.c b/gdk/win32/gdkevents-win32.c
index 1113de8887..1ceeacc57b 100644
--- a/gdk/win32/gdkevents-win32.c
+++ b/gdk/win32/gdkevents-win32.c
@@ -2665,7 +2665,16 @@ gdk_event_translate (MSG *msg,
case WM_EXITSIZEMOVE:
case WM_EXITMENULOOP:
- _gdk_win32_end_modal_call ();
+ if (_modal_operation_in_progress)
+ _gdk_win32_end_modal_call ();
+ break;
+
+ case WM_CAPTURECHANGED:
+ /* Sometimes we don't get WM_EXITSIZEMOVE, for instance when you
+ select move/size in the menu and then click somewhere without
+ moving/resizing. We work around this using WM_CAPTURECHANGED. */
+ if (_modal_operation_in_progress)
+ _gdk_win32_end_modal_call ();
break;
case WM_WINDOWPOSCHANGING: