public Main() { InitializeComponent(); Settings.install(); Settings.checkUpdate(); Settings.mainHandle = Handle; Settings.readSetting(); Utils.smoothBorder(minPanel, minPanel.Width); Utils.smoothBorder(exitPanel, exitPanel.Width); Utils.smoothBorder(this, 30); Utils.smoothBorder(mainPanel, 30); Directory.CreateDirectory(Settings.path); SetStyle( ControlStyles.UserPaint | ControlStyles.AllPaintingInWmPaint | ControlStyles.DoubleBuffer, true); easyFineTab = new EasyFineTab(); settingTab = new SettingTab(); settingTab.Visible = false; mainTabPanel.Controls.Add(easyFineTab); mainTabPanel.Controls.Add(settingTab); }
public MainWindowViewModel(MainTab mainTab, StatisticTab statisticTab, SettingTab settingTab, AboutTab aboutTab) { _mainTab = mainTab; _statisticTab = statisticTab; _settingTab = settingTab; _aboutTab = aboutTab; }
public bool ShowSettingTab(SettingTab tab) { using (FlagManager.UseFlag(nameof(ShowSettingTab))) { if (CurrentTab != null) { if (CurrentTab.Panel?.HasSettingsChanged ?? false) { return(false); } if (CurrentTab.Panel != null) { CurrentTab.Panel.Visible = false; } } CurrentTab = SettingsTabPanels.FirstOrDefault(x => x.Tab == tab); if (CurrentTab != null) { if (CurrentTab.Panel != null) { CurrentTab.Panel.Visible = true; } SelectTabInList(CurrentTab); return(true); } } return(false); }
public AppSettingsWindow() { InitializeComponent(); Icon = Properties.Resources.BrickStudioIcon; StartupTab = SettingTab.LddEnvironment; FlagManager = new FlagManager(); }
private void bunifuThinButton22_Click(object sender, EventArgs e) { SettingTab tab = new SettingTab(_user, this); tab.Visible = true; tab.StartInfo(); Controls.Add(tab); tab.Dock = DockStyle.Fill; tab.BringToFront(); }
public MainWindowViewModel(ILocalizationService localization, MainTab mainTab, StatisticTab statisticTab, SettingTab settingTab, AboutTab aboutTab) { Localization = localization.Data; _mainTab = mainTab; _statisticTab = statisticTab; _settingTab = settingTab; _aboutTab = aboutTab; }
void InitializeSettingTab() { settingTab = new SettingTab() { UserName = LocalCollaborateUserData.UserName, EMailAddress = LocalCollaborateUserData.EMailAddress }; // RemotePath Changed Handler settingTab.OnUserDataChanged += (dataName, url) => { if (dataName == "RemotePath") { var remoteList = LocalRepository.Network.Remotes; var remote = remoteList["origin"]; if (remote == null) { remote = remoteList.Add("origin", url); } else { remoteList.Update(remote, r => r.Url = url); } var masterBranch = LocalRepository.Branches["master"]; LocalRepository.Branches.Update(masterBranch, b => b.Remote = remote.Name, b => b.UpstreamBranch = masterBranch.CanonicalName ); } }; // UserName Changed Handler settingTab.OnUserDataChanged += (dataName, userName) => { if (dataName == "UserName") { LocalCollaborateUserData.UserName = userName; } }; // EMailAddress Changed Handler settingTab.OnUserDataChanged += (dataName, eMailAddress) => { if (dataName == "EMailAddress") { LocalCollaborateUserData.EMailAddress = eMailAddress; } }; }
public void SetTab(SettingTab settingTab, bool isSelected) { _localizedTabTitle.StringReference = settingTab.title; _currentTabType = settingTab.settingTabsType; if (isSelected) { SelectTab(); } else { UnselectTab(); } }
public void TabSwitch(int tabIdx) { switch (tabIdx) { case (int)SettingTab.SelectDevice: // Open Select Device Tab StopCoroutine(SearchConnectedDeviceList()); StartCoroutine(SearchConnectedDeviceList()); if (curTab == SettingTab.SelectDevice) { break; // 이미 열려 있는 탭이라면 } curTab = SettingTab.SelectDevice; SelectDeviceTab.SetActive(true); KeyCustomTab.SetActive(false); GameSettingTab.SetActive(false); break; case (int)SettingTab.KeyCustom: // Open Key Custom Tab if (curTab == SettingTab.KeyCustom) { break; } curTab = SettingTab.KeyCustom; SelectDeviceTab.SetActive(false); KeyCustomTab.SetActive(true); GameSettingTab.SetActive(false); break; case (int)SettingTab.GameSetting: if (curTab == SettingTab.GameSetting) { break; } curTab = SettingTab.GameSetting; SelectDeviceTab.SetActive(false); KeyCustomTab.SetActive(false); GameSettingTab.SetActive(true); break; } }
public SettingsTabNode(SettingTab tab, SettingsPanelBase panel) { Tab = tab; Panel = panel; Text = panel.Title; }
public SettingsTabNode(SettingTab tab, string text) { Tab = tab; Text = text; }