Skip to content

Commit b45debb

Browse files
[COMCTL32] Fix shift-selecting files not working as expected in small/large icons views (reactos#7729)
CORE-10386 Fixes the behavior when selecting multiple files in a folder with the Shift key, while using either the Large Icons or Small Icons view, so that it is consistent with how it works on Windows. Proposed changes: Disable the specialized code for these views in LISTVIEW_SetGroupSelection, using the same code as for the list and details views, which also works fine for them.
1 parent 14f8f7e commit b45debb

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

dll/win32/comctl32/listview.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3725,8 +3725,10 @@ static void LISTVIEW_SetGroupSelection(LISTVIEW_INFO *infoPtr, INT nItem)
37253725
item.state = LVIS_SELECTED;
37263726
item.stateMask = LVIS_SELECTED;
37273727

3728+
#ifndef __REACTOS__
37283729
if ((infoPtr->uView == LV_VIEW_LIST) || (infoPtr->uView == LV_VIEW_DETAILS))
37293730
{
3731+
#endif
37303732
if (infoPtr->nSelectionMark == -1)
37313733
{
37323734
infoPtr->nSelectionMark = nItem;
@@ -3740,6 +3742,7 @@ static void LISTVIEW_SetGroupSelection(LISTVIEW_INFO *infoPtr, INT nItem)
37403742
sel.upper = max(infoPtr->nSelectionMark, nItem) + 1;
37413743
ranges_add(selection, sel);
37423744
}
3745+
#ifndef __REACTOS__
37433746
}
37443747
else
37453748
{
@@ -3765,6 +3768,7 @@ static void LISTVIEW_SetGroupSelection(LISTVIEW_INFO *infoPtr, INT nItem)
37653768
}
37663769
iterator_destroy(&i);
37673770
}
3771+
#endif
37683772

37693773
/* disable per item notifications on LVS_OWNERDATA style
37703774
FIXME: single LVN_ODSTATECHANGED should be used */

0 commit comments

Comments
 (0)