public ControlPanel(SettingsMenu settingsMenu) { InitializeComponent(); btnManageGroup.Tag = ControlPanelOption.ManageGroup; btnChangeGroup.Tag = ControlPanelOption.SelectGroup; btnSettings.Tag = ControlPanelOption.ChangeSettings; btnTutorial.Tag = ControlPanelOption.Tutorial; btnExport.Tag = ControlPanelOption.ExportData; btnImport.Tag = ControlPanelOption.ImportData; btnLicense.Tag = ControlPanelOption.LicenseDetails; btnVerifyDB.Tag = ControlPanelOption.VerifyDB; btnLogout.Tag = ControlPanelOption.Logout; btnAbout.Tag = ControlPanelOption.About; btnQuit.Tag = ControlPanelOption.Quit; _settingsMenu = settingsMenu; _settingsMenu.Retract += new HideSettings(settings_Hide); _settingsMenu.SetControlPanel(this); }
private void Initialisation() { SettingsMenu settingsMenu = new SettingsMenu(); settingsMenu.MdiParent = this; // Setup the control panel. _controlPanel = new ControlPanel(settingsMenu); _controlPanel.Location = new Point(this.Width - _controlPanel.Width - 20, 10); _controlPanel.MdiParent = this; // note these two settings don't actually work for MDI child forms... _controlPanel.TopMost = true; _controlPanel.Opacity = .6; _controlPanel.OptionSelected += new CPOptionSelected(ControlPanel_OptionSelected); _controlPanel.Move += new EventHandler(ControlPanel_Move); // Setup default UI state RefreshDisplay(); if (WindowState == FormWindowState.Minimized) { Hide(); } //ValidateInstall(false); }