public void LoadConfigurations() { string configFile = FileUtils.GetConfigFile("hi2uc-config.xml"); // load from existing file if (File.Exists(configFile)) { _hiConfigs = HIConfigs.LoadConfiguration(configFile); } else { _hiConfigs = new HIConfigs(configFile); _hiConfigs.SaveConfigurations(); } _hearingImpaired = new HearingImpaired(_hiConfigs); }
public PluginForm(Subtitle subtitle, string name, string description) { InitializeComponent(); _subtitle = subtitle; labelDesc.Text = "Description: " + description; _hearingImpaired = new HearingImpaired(new Configuration() { MoodsToUppercase = true, NarratorToUppercase = true, Style = HIStyle.UpperCase }); /* * this.KeyDown += (s, e) => * { * if (e.KeyCode == Keys.Escape) * this.DialogResult = System.Windows.Forms.DialogResult.Cancel; * }; */ }