# HG changeset patch # User Juanma Barranquero # Date 1166139440 0 # Node ID 69b307896f8bc1f56cf72413d7b21c6e5ca43b72 # Parent 92a7d7de57cb33ebbca5f3f063b07c101de317f9 (w32_wnd_proc): Force non-tooltip frames to respect the minimum tracking size. Remove non-working old hack to do the same. diff -r 92a7d7de57cb -r 69b307896f8b src/w32fns.c --- a/src/w32fns.c Thu Dec 14 17:58:40 2006 +0000 +++ b/src/w32fns.c Thu Dec 14 23:37:20 2006 +0000 @@ -3706,8 +3706,11 @@ However for top/left sizing we will need to fix the X and Y positions as well. */ - lppos->cx -= wdiff; - lppos->cy -= hdiff; + int cx_mintrack = GetSystemMetrics (SM_CXMINTRACK); + int cy_mintrack = GetSystemMetrics (SM_CYMINTRACK); + + lppos->cx = max (lppos->cx - wdiff, cx_mintrack); + lppos->cy = max (lppos->cy - hdiff, cy_mintrack); if (wp.showCmd != SW_SHOWMAXIMIZED && (lppos->flags & SWP_NOMOVE) == 0) @@ -3731,9 +3734,6 @@ goto dflt; case WM_GETMINMAXINFO: - /* Hack to correct bug that allows Emacs frames to be resized - below the Minimum Tracking Size. */ - ((LPMINMAXINFO) lParam)->ptMinTrackSize.y++; /* Hack to allow resizing the Emacs frame above the screen size. Note that Windows 9x limits coordinates to 16-bits. */ ((LPMINMAXINFO) lParam)->ptMaxTrackSize.x = 32767;