Treeview item sorting could mess up the visibleOrder of the items.

This commit is contained in:
Aric Stewart 2000-11-02 20:09:43 +00:00 committed by Alexandre Julliard
parent 1f029ea6f5
commit cf94bf88c2
1 changed files with 4 additions and 1 deletions

View File

@ -2791,7 +2791,10 @@ TREEVIEW_Sort(TREEVIEW_INFO *infoPtr, BOOL fRecurse, HTREEITEM parent,
{
int visOrder = infoPtr->firstVisible->visibleOrder;
TREEVIEW_RecalculateVisibleOrder(infoPtr, parent);
if (parent == infoPtr->root)
TREEVIEW_RecalculateVisibleOrder(infoPtr, NULL);
else
TREEVIEW_RecalculateVisibleOrder(infoPtr, parent);
if (TREEVIEW_IsChildOf(parent, infoPtr->firstVisible))
{