Michael Stefaniuc : mshtml: Use EqualRect() to compare RECTs.
Module: wine Branch: master Commit: 41992ae38d1d0371b9ee70066f701a1fdae88d7a URL: http://source.winehq.org/git/wine.git/?a=commit;h=41992ae38d1d0371b9ee70066f... Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Thu Oct 20 10:24:06 2016 +0200 mshtml: Use EqualRect() to compare RECTs. Signed-off-by: Michael Stefaniuc <mstefani(a)redhat.de> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/mshtml/pluginhost.c | 2 +- dlls/mshtml/view.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/mshtml/pluginhost.c b/dlls/mshtml/pluginhost.c index 712f7e0..0fbbf6c 100644 --- a/dlls/mshtml/pluginhost.c +++ b/dlls/mshtml/pluginhost.c @@ -311,7 +311,7 @@ void update_plugin_window(PluginHost *host, HWND hwnd, const RECT *rect) TRACE("%p %s\n", hwnd, wine_dbgstr_rect(rect)); - if(memcmp(rect, &host->rect, sizeof(RECT))) { + if(!EqualRect(rect, &host->rect)) { host->rect = *rect; rect_changed = TRUE; } diff --git a/dlls/mshtml/view.c b/dlls/mshtml/view.c index 2a55938..15f39f4 100644 --- a/dlls/mshtml/view.c +++ b/dlls/mshtml/view.c @@ -507,7 +507,7 @@ static HRESULT WINAPI OleDocumentView_SetRect(IOleDocumentView *iface, LPRECT pr if(This->doc_obj->hwnd) { GetClientRect(This->doc_obj->hwnd, &rect); - if(memcmp(prcView, &rect, sizeof(RECT))) { + if(!EqualRect(prcView, &rect)) { InvalidateRect(This->doc_obj->hwnd, NULL, TRUE); SetWindowPos(This->doc_obj->hwnd, NULL, prcView->left, prcView->top, prcView->right, prcView->bottom, SWP_NOZORDER | SWP_NOACTIVATE);
participants (1)
-
Alexandre Julliard