From 125cc72499d36054cc77818be955bee89ac798af Mon Sep 17 00:00:00 2001 From: liufei Date: Tue, 12 Apr 2022 17:47:46 +0800 Subject: [PATCH] =?UTF-8?q?=E6=90=9C=E7=B4=A2=E6=A1=86=E9=9A=90=E8=97=8F?= =?UTF-8?q?=E6=97=B6=E4=B8=8D=E5=86=8D=E5=BC=80=E5=90=AF=E7=BA=BF=E7=A8=8B?= =?UTF-8?q?=E5=85=B3=E9=97=AD=E7=AA=97=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- MainWindow.xaml.cs | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/MainWindow.xaml.cs b/MainWindow.xaml.cs index fea1317..48eb13e 100644 --- a/MainWindow.xaml.cs +++ b/MainWindow.xaml.cs @@ -363,16 +363,21 @@ namespace GeekDesk public static void HideApp() { - if (RunTimeStatus.SEARCH_BOX_SHOW) mainWindow.HidedSearchBox(); - new Thread(() => + if (RunTimeStatus.SEARCH_BOX_SHOW) { - Thread.Sleep(100); - App.Current.Dispatcher.BeginInvoke(new Action(() => + mainWindow.HidedSearchBox(); + new Thread(() => { - FadeStoryBoard(0, (int)CommonEnum.WINDOW_ANIMATION_TIME, Visibility.Collapsed); - })); - }).Start(); - + Thread.Sleep(100); + App.Current.Dispatcher.BeginInvoke(new Action(() => + { + FadeStoryBoard(0, (int)CommonEnum.WINDOW_ANIMATION_TIME, Visibility.Collapsed); + })); + }).Start(); + } else + { + FadeStoryBoard(0, (int)CommonEnum.WINDOW_ANIMATION_TIME, Visibility.Collapsed); + } } ///