shell32: Avoid using CopyRect().

Signed-off-by: Michael Stefaniuc <mstefani@redhat.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Michael Stefaniuc 2016-06-22 11:54:09 +02:00 committed by Alexandre Julliard
parent ce88870982
commit ee3deec635
2 changed files with 4 additions and 5 deletions

View File

@ -498,7 +498,7 @@ static LRESULT navpane_splitter_beginresize(ExplorerBrowserImpl *This, HWND hwnd
SetCapture(hwnd); SetCapture(hwnd);
CopyRect(&This->splitter_rc, &This->navpane.rc); This->splitter_rc = This->navpane.rc;
This->splitter_rc.left = This->splitter_rc.right - SPLITTER_WIDTH; This->splitter_rc.left = This->splitter_rc.right - SPLITTER_WIDTH;
splitter_draw(GetParent(hwnd), &This->splitter_rc); splitter_draw(GetParent(hwnd), &This->splitter_rc);
@ -516,8 +516,7 @@ static LRESULT navpane_splitter_resizing(ExplorerBrowserImpl *This, HWND hwnd, L
dx = (SHORT)LOWORD(lParam); dx = (SHORT)LOWORD(lParam);
TRACE("%d.\n", dx); TRACE("%d.\n", dx);
CopyRect(&rc, &This->navpane.rc); rc = This->navpane.rc;
new_width = This->navpane.width + dx; new_width = This->navpane.width + dx;
if(new_width > NP_MIN_WIDTH && This->sv_rc.right - new_width > SV_MIN_WIDTH) if(new_width > NP_MIN_WIDTH && This->sv_rc.right - new_width > SV_MIN_WIDTH)
{ {
@ -525,7 +524,7 @@ static LRESULT navpane_splitter_resizing(ExplorerBrowserImpl *This, HWND hwnd, L
rc.left = rc.right - SPLITTER_WIDTH; rc.left = rc.right - SPLITTER_WIDTH;
splitter_draw(GetParent(hwnd), &This->splitter_rc); splitter_draw(GetParent(hwnd), &This->splitter_rc);
splitter_draw(GetParent(hwnd), &rc); splitter_draw(GetParent(hwnd), &rc);
CopyRect(&This->splitter_rc, &rc); This->splitter_rc = rc;
} }
return TRUE; return TRUE;

View File

@ -613,7 +613,7 @@ LRESULT WINAPI FileMenu_DrawItem(
clrPrevBkgnd = SetBkColor(lpdis->hDC, GetSysColor (COLOR_MENU)); clrPrevBkgnd = SetBkColor(lpdis->hDC, GetSysColor (COLOR_MENU));
} }
CopyRect(&TextRect, &(lpdis->rcItem)); TextRect = lpdis->rcItem;
/* add the menubitmap */ /* add the menubitmap */
menuinfo = FM_GetMenuInfo(pMyItem->hMenu); menuinfo = FM_GetMenuInfo(pMyItem->hMenu);