From 7e01792a373995af8d0901925fcbb129388dd57d Mon Sep 17 00:00:00 2001 From: leo Date: Tue, 1 Dec 2020 14:32:02 +0800 Subject: [PATCH] style: show update available window as dialog and centered in Launcher --- src/UI/Launcher.xaml.cs | 2 +- src/UI/UpdateAvailable.xaml | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/UI/Launcher.xaml.cs b/src/UI/Launcher.xaml.cs index c53aef96..a050f2c3 100644 --- a/src/UI/Launcher.xaml.cs +++ b/src/UI/Launcher.xaml.cs @@ -103,7 +103,7 @@ namespace SourceGit.UI { Dispatcher.Invoke(() => { var dialog = new UpdateAvailable(ver); dialog.Owner = this; - dialog.Show(); + dialog.ShowDialog(); }); } } catch { diff --git a/src/UI/UpdateAvailable.xaml b/src/UI/UpdateAvailable.xaml index 3dd6426d..80c500ec 100644 --- a/src/UI/UpdateAvailable.xaml +++ b/src/UI/UpdateAvailable.xaml @@ -5,7 +5,8 @@ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d" FontFamily="Consolas" - Height="400" Width="500"> + Height="400" Width="500" + WindowStartupLocation="CenterOwner" ResizeMode="NoResize">