Fully initialize context menus when they change (#38998)

If we don't slow-initialize the whole menu when it changes, then we won't see that there's secondary (& more) commands.  

Tested this with the extension from [waaverecords/CmdPal.Ext.Spotify#4](https://github.com/waaverecords/CmdPal.Ext.Spotify/pull/4)

Closes #38959 


Also seemingly closes #38347 - seems that needed additional bumping of the `EmptyContent`'s
This commit is contained in:
Mike Griese
2025-04-23 10:54:01 -05:00
committed by GitHub
parent b0e7473760
commit 54e058e82d
3 changed files with 10 additions and 2 deletions

View File

@@ -436,7 +436,7 @@ public partial class ListViewModel : PageViewModel, IDisposable
break;
case nameof(EmptyContent):
EmptyContent = new(new(model.EmptyContent), PageContext);
EmptyContent.InitializeProperties();
EmptyContent.SlowInitializeProperties();
break;
case nameof(IsLoading):
UpdateEmptyContent();
@@ -454,6 +454,8 @@ public partial class ListViewModel : PageViewModel, IDisposable
return;
}
UpdateProperty(nameof(EmptyContent));
DoOnUiThread(
() =>
{