private void Button_AddHotkey_Click(object sender, RoutedEventArgs e)
        {
            CollectionHotkeyEditWindow collectionHotkeyEdit = new CollectionHotkeyEditWindow();

            collectionHotkeyEdit.ShowDialog();
            if (collectionHotkeyEdit.KeyInformation.HasValue)
            {
                CollectionKeyInformation keyInformation = collectionHotkeyEdit.KeyInformation.Value;
                CollectionStore.Settings.AddHotkey(keyInformation);
                listBox_Hotkeys.Items.Refresh();
            }
        }
 private void Button_EditHotkey_Click(object sender, RoutedEventArgs e)
 {
     if (listBox_Hotkeys.SelectedItem != null)
     {
         KeyValuePair <Hotkey, string> item = (KeyValuePair <Hotkey, string>)listBox_Hotkeys.SelectedItem;
         CollectionHotkeyEditWindow    collectionHotkeyEdit = new CollectionHotkeyEditWindow(item.Key);
         collectionHotkeyEdit.ShowDialog();
         if (collectionHotkeyEdit.KeyInformation.HasValue)
         {
             CollectionKeyInformation    keyInformation = collectionHotkeyEdit.KeyInformation.Value;
             Dictionary <Hotkey, string> hotkeys        = CollectionStore.Settings.CollectionHotkeys;
             if (hotkeys.ContainsKey(keyInformation.Hotkey))
             {
                 CollectionStore.Settings.SetHotkeyCollection(keyInformation);
             }
             else
             {
                 CollectionStore.Settings.AddHotkey(keyInformation);
             }
             listBox_Hotkeys.Items.Refresh();
         }
     }
 }