Daniel Jelinski : comctl32: Use GetWindowLong to check for scrollbar.

Alexandre Julliard julliard at winehq.org
Mon Oct 1 13:35:02 CDT 2012


Module: wine
Branch: master
Commit: 0edb0233a46e7105cb8c88093ca07c741123c8c3
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=0edb0233a46e7105cb8c88093ca07c741123c8c3

Author: Daniel Jelinski <djelinski1 at gmail.com>
Date:   Fri Sep 21 21:58:43 2012 +0200

comctl32: Use GetWindowLong to check for scrollbar.

dwStyle is updated only in WM_STYLECHANGED, which is not sent
when displaying and hiding scrollbars.

---

 dlls/comctl32/listview.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/dlls/comctl32/listview.c b/dlls/comctl32/listview.c
index 7a11557..0ef8bc4 100644
--- a/dlls/comctl32/listview.c
+++ b/dlls/comctl32/listview.c
@@ -10878,7 +10878,7 @@ static void LISTVIEW_UpdateSize(LISTVIEW_INFO *infoPtr)
 	 * The "2" is there to mimic the native control. I think it may be
 	 * related to either padding or edges.  (GLA 7/2002)
 	 */
-	if (!(infoPtr->dwStyle & WS_HSCROLL))
+	if (!(GetWindowLongW(infoPtr->hwndSelf, GWL_STYLE) & WS_HSCROLL))
 	    infoPtr->rcList.bottom -= GetSystemMetrics(SM_CYHSCROLL);
         infoPtr->rcList.bottom = max (infoPtr->rcList.bottom - 2, 0);
     }




More information about the wine-cvs mailing list