From b032b4ac00410687144c77abeafcaa2137a609f8 Mon Sep 17 00:00:00 2001 From: Aigio Liu Date: Tue, 27 Apr 2021 01:47:36 +0800 Subject: [PATCH] App.IsMini --- src/ST.Client.Desktop.Avalonia.App/App.axaml.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/ST.Client.Desktop.Avalonia.App/App.axaml.cs b/src/ST.Client.Desktop.Avalonia.App/App.axaml.cs index 74384befc..7dfe8628b 100644 --- a/src/ST.Client.Desktop.Avalonia.App/App.axaml.cs +++ b/src/ST.Client.Desktop.Avalonia.App/App.axaml.cs @@ -242,12 +242,12 @@ namespace System.Application.UI IsNotOfficialChannelPackageWarning(); } } + + desktop.MainWindow = #if !UI_DEMO - if (Program.IsMinimize) - desktop.MainWindow = null; - else + Program.IsMinimize ? null : #endif - desktop.MainWindow = MainWindow; + MainWindow; desktop.Startup += Desktop_Startup; desktop.Exit += ApplicationLifetime_Exit;