comctl32/status: Hide size grip when the parent window is maximized.
Signed-off-by: Waritnan Sookbuntherng <lion328@hotmail.co.th> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
d8428406c6
commit
1bb95af322
|
@ -284,7 +284,8 @@ STATUSBAR_Refresh (STATUS_INFO *infoPtr, HDC hdc)
|
||||||
|
|
||||||
SelectObject (hdc, hOldFont);
|
SelectObject (hdc, hOldFont);
|
||||||
|
|
||||||
if (GetWindowLongW (infoPtr->Self, GWL_STYLE) & SBARS_SIZEGRIP)
|
if ((GetWindowLongW (infoPtr->Self, GWL_STYLE) & SBARS_SIZEGRIP)
|
||||||
|
&& !(GetWindowLongW (infoPtr->Notify, GWL_STYLE) & WS_MAXIMIZE))
|
||||||
STATUSBAR_DrawSizeGrip (theme, hdc, &rect);
|
STATUSBAR_DrawSizeGrip (theme, hdc, &rect);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -997,7 +998,8 @@ STATUSBAR_WMGetText (const STATUS_INFO *infoPtr, INT size, LPWSTR buf)
|
||||||
static BOOL
|
static BOOL
|
||||||
STATUSBAR_WMNCHitTest (const STATUS_INFO *infoPtr, INT x, INT y)
|
STATUSBAR_WMNCHitTest (const STATUS_INFO *infoPtr, INT x, INT y)
|
||||||
{
|
{
|
||||||
if (GetWindowLongW (infoPtr->Self, GWL_STYLE) & SBARS_SIZEGRIP) {
|
if ((GetWindowLongW (infoPtr->Self, GWL_STYLE) & SBARS_SIZEGRIP)
|
||||||
|
&& !(GetWindowLongW (infoPtr->Notify, GWL_STYLE) & WS_MAXIMIZE)) {
|
||||||
RECT rect;
|
RECT rect;
|
||||||
POINT pt;
|
POINT pt;
|
||||||
|
|
||||||
|
|
|
@ -682,7 +682,7 @@ static void test_sizegrip(void)
|
||||||
r = SendMessageA(hwndStatus, WM_NCHITTEST, 0, MAKELPARAM(rc.right, rc.bottom + 1));
|
r = SendMessageA(hwndStatus, WM_NCHITTEST, 0, MAKELPARAM(rc.right, rc.bottom + 1));
|
||||||
expect(HTNOWHERE, r);
|
expect(HTNOWHERE, r);
|
||||||
r = SendMessageA(hwndStatus, WM_NCHITTEST, 0, MAKELPARAM(rc.right - 1, rc.bottom - 1));
|
r = SendMessageA(hwndStatus, WM_NCHITTEST, 0, MAKELPARAM(rc.right - 1, rc.bottom - 1));
|
||||||
todo_wine expect(HTCLIENT, r);
|
expect(HTCLIENT, r);
|
||||||
|
|
||||||
/* maximized with right-to-left */
|
/* maximized with right-to-left */
|
||||||
SetWindowLongA(hwndStatus, GWL_EXSTYLE, WS_EX_LAYOUTRTL);
|
SetWindowLongA(hwndStatus, GWL_EXSTYLE, WS_EX_LAYOUTRTL);
|
||||||
|
@ -705,7 +705,7 @@ static void test_sizegrip(void)
|
||||||
r = SendMessageA(hwndStatus, WM_NCHITTEST, 0, MAKELPARAM(rc.right, rc.bottom + 1));
|
r = SendMessageA(hwndStatus, WM_NCHITTEST, 0, MAKELPARAM(rc.right, rc.bottom + 1));
|
||||||
expect(HTNOWHERE, r);
|
expect(HTNOWHERE, r);
|
||||||
r = SendMessageA(hwndStatus, WM_NCHITTEST, 0, MAKELPARAM(rc.right + 1, rc.bottom - 1));
|
r = SendMessageA(hwndStatus, WM_NCHITTEST, 0, MAKELPARAM(rc.right + 1, rc.bottom - 1));
|
||||||
todo_wine expect(HTCLIENT, r);
|
expect(HTCLIENT, r);
|
||||||
|
|
||||||
SetWindowLongA(g_hMainWnd, GWL_STYLE, style);
|
SetWindowLongA(g_hMainWnd, GWL_STYLE, style);
|
||||||
DestroyWindow(hwndStatus);
|
DestroyWindow(hwndStatus);
|
||||||
|
|
Loading…
Reference in New Issue