public static string GetAddOn() { string retVal = null; AddOnSelector win = new AddOnSelector(); if (win.ShowDialog() == true) { retVal = win.SelectedAddOn; } return(retVal); }
private void OnNewAddOn(object sender, RoutedEventArgs e) { if (Captions.Count > 0) { switch (MessageBox.Show("Save captions?", "Save", MessageBoxButton.YesNoCancel, MessageBoxImage.Question)) { case MessageBoxResult.Yes: Save(SelectedLanguage, AddOn); break; case MessageBoxResult.No: break; case MessageBoxResult.Cancel: return; } } AddOn = AddOnSelector.GetAddOn(); }
private void OnLoaded(object sender, RoutedEventArgs e) { AddOn = AddOnSelector.GetAddOn(); }