private void PART_Mnu_GlobalHotkey_Click(object sender, RoutedEventArgs e) { EditHotKeyWindow winEditHotKey = new EditHotKeyWindow(); winEditHotKey.Owner = App.MainAppWindow; winEditHotKey.Topmost = App.MainAppWindow.Topmost; winEditHotKey.ShowDialog(); if (winEditHotKey.DialogResult == true) { HOTKEY_system.Enabled = false; Settings.SettingsDatabase.IsHotkeyEnabled = (bool)winEditHotKey.CHECK_EnableHotkey.IsChecked; if (Settings.SettingsDatabase.IsHotkeyEnabled) { Settings.SettingsDatabase.HotkeyModifiers = winEditHotKey.ModifierKeys; Settings.SettingsDatabase.Hotkey = winEditHotKey.Keys; HOTKEY_system.Modifiers = Settings.SettingsDatabase.HotkeyModifiers; HOTKEY_system.Key = Settings.SettingsDatabase.Hotkey; HOTKEY_system.Enabled = Settings.SettingsDatabase.IsHotkeyEnabled; } PART_Mnu_GlobalHotkey.IsChecked = Settings.SettingsDatabase.IsHotkeyEnabled; PART_Mnu_GlobalHotkey.Header = "Enable Global Hotkey (" + Settings.SettingsDatabase.HotkeyString + ")"; } }