mirror of
git://source.winehq.org/git/wine.git
synced 2024-10-31 12:19:49 +00:00
Do not autoarrange if we insert/delete from the end of the list.
This commit is contained in:
parent
c5da549d10
commit
9ff0da09ff
1 changed files with 6 additions and 1 deletions
|
@ -4045,7 +4045,12 @@ static void LISTVIEW_ScrollOnInsert(LISTVIEW_INFO *infoPtr, INT nItem, INT dir)
|
|||
|
||||
/* arrange icons if autoarrange is on */
|
||||
if (infoPtr->dwStyle & LVS_AUTOARRANGE)
|
||||
LISTVIEW_Arrange(infoPtr, LVA_DEFAULT);
|
||||
{
|
||||
BOOL arrange = TRUE;
|
||||
if (dir < 0 && nItem >= infoPtr->nItemCount) arrange = FALSE;
|
||||
if (dir > 0 && nItem == infoPtr->nItemCount - 1) arrange = FALSE;
|
||||
if (arrange) LISTVIEW_Arrange(infoPtr, LVA_DEFAULT);
|
||||
}
|
||||
|
||||
/* scrollbars need updating */
|
||||
LISTVIEW_UpdateScroll(infoPtr);
|
||||
|
|
Loading…
Reference in a new issue