mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-03 09:46:54 +02:00
CmdPal: Remove support for "selection" TextToSuggest (#41956)
`TextToSuggest` has been nothing but pain. We need another approach. I'm leaving the code, but just disabled behind an env flag. Same as actions. Closes #41659
This commit is contained in:
@@ -25,7 +25,7 @@ public partial class ContentTreeViewModel(ITreeContent _tree, WeakReference<IPag
|
||||
|
||||
// This is the content that's actually bound in XAML. We needed a
|
||||
// collection, even if the collection is just a single item.
|
||||
public ObservableCollection<ContentViewModel> Root => [RootContent];
|
||||
public ObservableCollection<ContentViewModel> Root => RootContent is not null ? [RootContent] : [];
|
||||
|
||||
public override void InitializeProperties()
|
||||
{
|
||||
@@ -122,7 +122,7 @@ public partial class ContentTreeViewModel(ITreeContent _tree, WeakReference<IPag
|
||||
if (viewModel is not null)
|
||||
{
|
||||
viewModel.InitializeProperties();
|
||||
newContent.Add(viewModel);
|
||||
newContent.Add((ContentViewModel)viewModel);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user