src/TF2HUD.Editor/MainWindow.xaml.cs
/// <summary>
///     Add a HUD from folder to the shared HUDs list.
/// </summary>
Add a HUD from folder to the shared HUDs list.
Add a HUD from folder to the shared HUDs list .
private void BtnAddSharedHUD_OnClick(object sender, RoutedEventArgs e)
        {
            try
            {
                if (_notifier.ShowMessageBox(MessageBoxImage.Information, Properties.Resources.info_add_hud, MessageBoxButton.YesNoCancel) != MessageBoxResult.Yes) return;
                var browser = new FolderBrowserDialog
                {
                    SelectedPath = HudPath + "\\"
                };
                if (browser.ShowDialog() != System.Windows.Forms.DialogResult.OK) return;
                AddHUDToGridView(Json.Add(browser.SelectedPath));
            }
            catch (Exception error)
            {
                _notifier.ShowMessageBox(MessageBoxImage.Error, error.Message);
            }
        }
private void BtnAddSharedHUD_OnClick ( object sender , RoutedEventArgs e ) { try { if ( _notifier . ShowMessageBox ( MessageBoxImage . Information , Properties . Resources . info_add_hud , MessageBoxButton . YesNoCancel ) != MessageBoxResult . Yes ) return ; var browser = new FolderBrowserDialog { SelectedPath = HudPath + " \\ " } ; if ( browser . ShowDialog ( ) != System . Windows . Forms . DialogResult . OK ) return ; AddHUDToGridView ( Json . Add ( browser . SelectedPath ) ) ; } catch ( Exception error ) { _notifier . ShowMessageBox ( MessageBoxImage . Error , error . Message ) ; } }
Add a HUD from folder to the shared HUDs list.
Add a HUD from folder to the shared HUDs list .
sender
object
e
RoutedEventArgs