Merge pull request #982 from markatosi/develop

Change Example code for AutoMenuHide
This commit is contained in:
Florian Rappl
2025-12-13 12:28:41 +01:00
committed by GitHub

View File

@@ -133,9 +133,10 @@ builder.UseElectron(args, async () =>
{
var options = new BrowserWindowOptions {
Show = false,
AutoHideMenuBar = true,
IsRunningBlazor = true, // <-- crucial
};
if (OperatingSystem.IsWindows() || OperatingSystem.IsLinux())
options.AutoHideMenuBar = true;
var browserWindow = await Electron.WindowManager.CreateWindowAsync(options);
browserWindow.OnReadyToShow += () => browserWindow.Show();
});