diff --git a/osrs-toolbox/Views/HomePageView.xaml b/osrs-toolbox/Views/HomePageView.xaml index ed1c7e1..1057787 100644 --- a/osrs-toolbox/Views/HomePageView.xaml +++ b/osrs-toolbox/Views/HomePageView.xaml @@ -5,7 +5,7 @@ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:local="clr-namespace:osrs_toolbox" mc:Ignorable="d" - Title="OSRS Toolbox" d:Height="450" d:Width="800" SizeToContent="WidthAndHeight"> + Title="OSRS Toolbox" d:Height="450" d:Width="800" SizeToContent="WidthAndHeight" Closed="Window_Closed"> @@ -25,12 +25,12 @@ - + - + diff --git a/osrs-toolbox/Views/HomePageView.xaml.cs b/osrs-toolbox/Views/HomePageView.xaml.cs index cd94ffb..8f634ae 100644 --- a/osrs-toolbox/Views/HomePageView.xaml.cs +++ b/osrs-toolbox/Views/HomePageView.xaml.cs @@ -26,5 +26,12 @@ namespace osrs_toolbox InitializeComponent(); Current = this; } + + private void Window_Closed(object sender, EventArgs e) + { + foreach (Window w in Application.Current.Windows) + w.Close(); + Application.Current.Shutdown(); + } } }