public MainForm(string[] args) { if (args.Length > 0) { this.initialConnectionName = ExtractSwitchValue("/connection:", ref args); this.initialPluginName = ExtractSwitchValue("/plugin:", ref args); } InitializeComponent(); ProcessMenuItemsForPlugin(); MouseWheel += (sender, e) => HomePageTab.Focus(); currentOptions = Options.Load(); Text = string.Format("{0} (v{1})", Text, Assembly.GetExecutingAssembly().GetName().Version); ManageConnectionControl(); }
public MainForm(string[] args) { SetStyle(ControlStyles.OptimizedDoubleBuffer, true); SetStyle(ControlStyles.AllPaintingInWmPaint, true); if (args.Length > 0) { this.initialConnectionName = ExtractSwitchValue("/connection:", ref args); this.initialPluginName = ExtractSwitchValue("/plugin:", ref args); } InitializeComponent(); pluginsModels = new List<PluginModel>(); pluginControlStatuses = new List<PluginControlStatus>(); ProcessMenuItemsForPlugin(); MouseWheel += (sender, e) => pnlPlugins.Focus(); currentOptions = Options.Load(); Text = string.Format("{0} (v{1})", Text, Assembly.GetExecutingAssembly().GetName().Version); ManageConnectionControl(); }
private void TsbOptionsClick(object sender, EventArgs e) { var oDialog = new OptionsDialog(currentOptions, pManager); if (oDialog.ShowDialog(this) == DialogResult.OK) { bool reinitDisplay = currentOptions.DisplayMostUsedFirst != oDialog.Option.DisplayMostUsedFirst || currentOptions.MostUsedList.Count != oDialog.Option.MostUsedList.Count || currentOptions.DisplayLargeIcons != oDialog.Option.DisplayLargeIcons || !oDialog.Option.HiddenPlugins.SequenceEqual(currentOptions.HiddenPlugins); currentOptions = oDialog.Option; if (reinitDisplay) { //pManager.PluginsControls.Clear(); pluginsModels.Clear(); tabControl1.SelectedIndex = 0; DisplayPlugins(tstxtFilterPlugin.Text); AdaptPluginControlSize(); } } }