Nikolay Sivov : comctl32/listview: Remove internal autoarrange flag, it breaks positioning.

Alexandre Julliard julliard at winehq.org
Wed May 3 16:06:10 CDT 2017


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

Author: Nikolay Sivov <nsivov at codeweavers.com>
Date:   Wed May  3 14:09:27 2017 +0300

comctl32/listview: Remove internal autoarrange flag, it breaks positioning.

Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

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

diff --git a/dlls/comctl32/listview.c b/dlls/comctl32/listview.c
index c01d816..acafbd3 100644
--- a/dlls/comctl32/listview.c
+++ b/dlls/comctl32/listview.c
@@ -249,7 +249,6 @@ typedef struct tagLISTVIEW_INFO
   RANGES selectionRanges;
   INT nSelectionMark;           /* item to start next multiselection from */
   INT nHotItem;
-  BOOL bAutoarrange;		/* Autoarrange flag when NOT in LVS_AUTOARRANGE */
 
   /* columns */
   HDPA hdpaColumns;		/* array of COLUMN_INFO pointers */
@@ -1584,8 +1583,8 @@ static inline LRESULT CallWindowProcT(WNDPROC proc, HWND hwnd, UINT uMsg,
 
 static inline BOOL is_autoarrange(const LISTVIEW_INFO *infoPtr)
 {
-    return ((infoPtr->dwStyle & LVS_AUTOARRANGE) || infoPtr->bAutoarrange) &&
-	   (infoPtr->uView == LV_VIEW_ICON || infoPtr->uView == LV_VIEW_SMALLICON);
+    return (infoPtr->dwStyle & LVS_AUTOARRANGE) &&
+        (infoPtr->uView == LV_VIEW_ICON || infoPtr->uView == LV_VIEW_SMALLICON);
 }
 
 static void toggle_checkbox_state(LISTVIEW_INFO *infoPtr, INT nItem)
@@ -2782,7 +2781,6 @@ static BOOL LISTVIEW_Arrange(LISTVIEW_INFO *infoPtr, INT nAlignCode)
     default: return FALSE;
     }
     
-    infoPtr->bAutoarrange = TRUE;
     infoPtr->currIconPos.x = infoPtr->currIconPos.y = 0;
     for (i = 0; i < infoPtr->nItemCount; i++)
     {
@@ -8936,8 +8934,6 @@ static BOOL LISTVIEW_SetItemPosition(LISTVIEW_INFO *infoPtr, INT nItem, const PO
     Pt.x -= Origin.x;
     Pt.y -= Origin.y;
 
-    infoPtr->bAutoarrange = FALSE;
-
     return LISTVIEW_MoveIconTo(infoPtr, nItem, &Pt, FALSE);
 }
 




More information about the wine-cvs mailing list