Skip to content

Commit

Permalink
[Power Rename] Select all while filter is active (microsoft#24598)
Browse files Browse the repository at this point in the history
* Check if the result from find item returns a valid item
and repopulate ExplorerItems()

* Call all the clean and populate methods only
when showRenamed is checked.
  • Loading branch information
sosssego authored and BLM16 committed Jun 22, 2023
1 parent bc33916 commit 341eabf
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/modules/powerrename/PowerRenameUILib/MainWindow.xaml.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,13 @@ namespace winrt::PowerRenameUI::implementation
{
ToggleAll();
m_allSelected = !m_allSelected;
if (button_showRenamed().IsChecked())
{
m_explorerItems.Clear();
m_explorerItemsMap.clear();
PopulateExplorerItems();
UpdateCounts();
}
}
}

Expand Down Expand Up @@ -738,7 +745,8 @@ namespace winrt::PowerRenameUI::implementation
int id = 0;
spItem->GetId(&id);
auto item = FindById(id);
item.Checked(selected);
if (item)
item.Checked(selected);
}
}
UpdateCounts();
Expand Down

0 comments on commit 341eabf

Please sign in to comment.