From 998ad2aa87a081309a7f0ed013c2202e040c09ce Mon Sep 17 00:00:00 2001 From: Don HO Date: Wed, 18 Dec 2019 10:37:20 +0100 Subject: [PATCH] Optimize the recursive folding in TreeView --- PowerEditor/src/WinControls/ProjectPanel/TreeView.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PowerEditor/src/WinControls/ProjectPanel/TreeView.cpp b/PowerEditor/src/WinControls/ProjectPanel/TreeView.cpp index b41bc258..f4b47dd2 100644 --- a/PowerEditor/src/WinControls/ProjectPanel/TreeView.cpp +++ b/PowerEditor/src/WinControls/ProjectPanel/TreeView.cpp @@ -275,7 +275,6 @@ void TreeView::foldRecursively(HTREEITEM hParentItem) const foldRecursively(hItem); fold(hItem); } - fold(hParentItem); } void TreeView::foldAll() const @@ -285,6 +284,7 @@ void TreeView::foldAll() const tvProj = getNextSibling(tvProj)) { foldRecursively(tvProj); + fold(tvProj); } }