public OptionsForm(MainApplicationContext main) { this.main = main; this.selectedKeys = main.HotKey?.KeyCombination ?? KeyCombination.None; InitializeComponent(); // --- General section --- chkTruncateTitle.Checked = Settings.Default.TitleLengthLimit < int.MaxValue; numLimit.Value = Settings.Default.TitleLengthLimit; chkHotKey.Checked = main.HotKey != null; panHotKey.Enabled = chkHotKey.Checked; txtHotKey.Text = selectedKeys.ToString(); // --- Application section --- chkUpdates.Checked = Settings.Default.AlwaysCheckForUpdates; }