private void ProxyWindowVisible_Click(object sender, EventArgs e) { if (ProxyWindow.Checked) { ProxyPage.Hide(); } else { ProxyPage.Show(MainDockPanel, DockState.Document); } ProxyWindow.Checked = !ProxyWindow.Checked; }
private void LoadViewSetting() { if (System.IO.File.Exists(Config.ViewSettingFileName)) { var setting = XmlHelper.XmlDeserialize( Config.ViewSettingFileName, typeof(ViewSetting)) as ViewSetting; if (setting != null) { Config.LocalSetting.NeedDebug = Debug.Checked = setting.EnableDebug; InfomationWindow.Checked = setting.InformationWindow; if (InfomationWindow.Checked) { InfoPage.Show(); } else { InfoPage.Hide(); } ProxyWindow.Checked = setting.ProxyWindow; if (ProxyWindow.Checked) { ProxyPage.Show(); } else { ProxyPage.Hide(); } MainStatusBar.Visible = RightStatusBar.Checked = StatusBar.Checked = setting.StatusBar; MainToolbar.Visible = RightToolBar.Checked = ToolBar.Checked = setting.ToolBar; MainMenu.Visible = RightMenuBar.Checked = MenuBar.Checked = setting.MenuBar; } else { System.IO.File.Delete(Config.ViewSettingFileName); SplashScreen.CloseSplashScreen(); _hasViewSettingException = true; MsgBox.ShowErrorMessage("ViewSetting.xml not found!"); Close(); } } }