From f7cfe4e393e8e517a011e81fa5dfc4791fb12f86 Mon Sep 17 00:00:00 2001 From: adelikat Date: Mon, 21 Jul 2014 23:18:18 +0000 Subject: [PATCH] Path Config - 1. remove Global Base from top and leave it in the Global tab, 2. Rename Global Tabs "base rom" to "ROM" --- BizHawk.Client.Common/config/PathEntry.cs | 2 +- .../config/PathConfig.Designer.cs | 55 +++---------------- BizHawk.Client.EmuHawk/config/PathConfig.cs | 16 ------ 3 files changed, 9 insertions(+), 64 deletions(-) diff --git a/BizHawk.Client.Common/config/PathEntry.cs b/BizHawk.Client.Common/config/PathEntry.cs index 5f6427056d..2f3697ba2f 100644 --- a/BizHawk.Client.Common/config/PathEntry.cs +++ b/BizHawk.Client.Common/config/PathEntry.cs @@ -146,7 +146,7 @@ namespace BizHawk.Client.Common return new List { new PathEntry { System = "Global_NULL", SystemDisplayName="Global", Type = "Base", Path = ".", Ordinal = 1 }, - new PathEntry { System = "Global_NULL", SystemDisplayName="Global", Type = "Base ROM", Path = ".", Ordinal = 2 }, + new PathEntry { System = "Global_NULL", SystemDisplayName="Global", Type = "ROM", Path = ".", Ordinal = 2 }, new PathEntry { System = "Global_NULL", SystemDisplayName="Global", Type = "Firmware", Path = Path.Combine(".", "Firmware"), Ordinal = 3 }, new PathEntry { System = "Global_NULL", SystemDisplayName="Global", Type = "Movies", Path = Path.Combine(".", "Movies"), Ordinal = 4 }, new PathEntry { System = "Global_NULL", SystemDisplayName="Global", Type = "Movie backups", Path = Path.Combine(".", "Movies", "backup"), Ordinal = 5 }, diff --git a/BizHawk.Client.EmuHawk/config/PathConfig.Designer.cs b/BizHawk.Client.EmuHawk/config/PathConfig.Designer.cs index 6bf3e52d8e..9c32d716cf 100644 --- a/BizHawk.Client.EmuHawk/config/PathConfig.Designer.cs +++ b/BizHawk.Client.EmuHawk/config/PathConfig.Designer.cs @@ -35,9 +35,6 @@ this.label1 = new System.Windows.Forms.Label(); this.SpecialCommandsBtn = new System.Windows.Forms.Button(); this.RecentForROMs = new System.Windows.Forms.CheckBox(); - this.BasePathBox = new System.Windows.Forms.TextBox(); - this.BrowseBase = new System.Windows.Forms.Button(); - this.BaseDescription = new System.Windows.Forms.Label(); this.DefaultsBtn = new System.Windows.Forms.Button(); this.SuspendLayout(); // @@ -66,14 +63,14 @@ // // PathTabControl // - this.PathTabControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) - | System.Windows.Forms.AnchorStyles.Left) - | System.Windows.Forms.AnchorStyles.Right))); - this.PathTabControl.Location = new System.Drawing.Point(12, 84); + this.PathTabControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + | System.Windows.Forms.AnchorStyles.Left) + | System.Windows.Forms.AnchorStyles.Right))); + this.PathTabControl.Location = new System.Drawing.Point(12, 41); this.PathTabControl.Multiline = true; this.PathTabControl.Name = "PathTabControl"; this.PathTabControl.SelectedIndex = 0; - this.PathTabControl.Size = new System.Drawing.Size(615, 321); + this.PathTabControl.Size = new System.Drawing.Size(615, 364); this.PathTabControl.TabIndex = 2; // // SaveBtn @@ -91,7 +88,7 @@ // this.label1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.label1.AutoSize = true; - this.label1.Location = new System.Drawing.Point(527, 52); + this.label1.Location = new System.Drawing.Point(527, 19); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(97, 13); this.label1.TabIndex = 210; @@ -101,7 +98,7 @@ // this.SpecialCommandsBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.SpecialCommandsBtn.Image = global::BizHawk.Client.EmuHawk.Properties.Resources.Help; - this.SpecialCommandsBtn.Location = new System.Drawing.Point(496, 47); + this.SpecialCommandsBtn.Location = new System.Drawing.Point(496, 14); this.SpecialCommandsBtn.Name = "SpecialCommandsBtn"; this.SpecialCommandsBtn.Size = new System.Drawing.Size(26, 23); this.SpecialCommandsBtn.TabIndex = 209; @@ -111,7 +108,7 @@ // RecentForROMs // this.RecentForROMs.AutoSize = true; - this.RecentForROMs.Location = new System.Drawing.Point(12, 51); + this.RecentForROMs.Location = new System.Drawing.Point(12, 18); this.RecentForROMs.Name = "RecentForROMs"; this.RecentForROMs.Size = new System.Drawing.Size(184, 17); this.RecentForROMs.TabIndex = 207; @@ -119,36 +116,6 @@ this.RecentForROMs.UseVisualStyleBackColor = true; this.RecentForROMs.CheckedChanged += new System.EventHandler(this.RecentForROMs_CheckedChanged); // - // BasePathBox - // - this.BasePathBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) - | System.Windows.Forms.AnchorStyles.Right))); - this.BasePathBox.Location = new System.Drawing.Point(12, 15); - this.BasePathBox.Name = "BasePathBox"; - this.BasePathBox.Size = new System.Drawing.Size(510, 20); - this.BasePathBox.TabIndex = 205; - // - // BrowseBase - // - this.BrowseBase.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.BrowseBase.Image = global::BizHawk.Client.EmuHawk.Properties.Resources.OpenFile; - this.BrowseBase.Location = new System.Drawing.Point(530, 14); - this.BrowseBase.Name = "BrowseBase"; - this.BrowseBase.Size = new System.Drawing.Size(26, 23); - this.BrowseBase.TabIndex = 206; - this.BrowseBase.UseVisualStyleBackColor = true; - this.BrowseBase.Click += new System.EventHandler(this.BrowseBase_Click); - // - // BaseDescription - // - this.BaseDescription.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.BaseDescription.AutoSize = true; - this.BaseDescription.Location = new System.Drawing.Point(563, 19); - this.BaseDescription.Name = "BaseDescription"; - this.BaseDescription.Size = new System.Drawing.Size(64, 13); - this.BaseDescription.TabIndex = 208; - this.BaseDescription.Text = "Global Base"; - // // DefaultsBtn // this.DefaultsBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); @@ -171,9 +138,6 @@ this.Controls.Add(this.label1); this.Controls.Add(this.SpecialCommandsBtn); this.Controls.Add(this.RecentForROMs); - this.Controls.Add(this.BasePathBox); - this.Controls.Add(this.BrowseBase); - this.Controls.Add(this.BaseDescription); this.Controls.Add(this.SaveBtn); this.Controls.Add(this.PathTabControl); this.Controls.Add(this.Cancel); @@ -198,9 +162,6 @@ private System.Windows.Forms.Label label1; private System.Windows.Forms.Button SpecialCommandsBtn; private System.Windows.Forms.CheckBox RecentForROMs; - private System.Windows.Forms.TextBox BasePathBox; - private System.Windows.Forms.Button BrowseBase; - private System.Windows.Forms.Label BaseDescription; private System.Windows.Forms.Button DefaultsBtn; } } \ No newline at end of file diff --git a/BizHawk.Client.EmuHawk/config/PathConfig.cs b/BizHawk.Client.EmuHawk/config/PathConfig.cs index dfd2731d89..56cd6a2581 100644 --- a/BizHawk.Client.EmuHawk/config/PathConfig.cs +++ b/BizHawk.Client.EmuHawk/config/PathConfig.cs @@ -52,7 +52,6 @@ namespace BizHawk.Client.EmuHawk private void LoadSettings() { RecentForROMs.Checked = Global.Config.UseRecentForROMs; - BasePathBox.Text = Global.Config.PathEntries.GlobalBaseFragment; DoTabs(Global.Config.PathEntries.ToList()); SetDefaultFocusedTab(); @@ -221,7 +220,6 @@ namespace BizHawk.Client.EmuHawk private void SaveSettings() { Global.Config.UseRecentForROMs = RecentForROMs.Checked; - Global.Config.PathEntries["Global", "Base"].Path = BasePathBox.Text; foreach (var t in AllPathBoxes) { @@ -284,20 +282,6 @@ namespace BizHawk.Client.EmuHawk DoRomToggle(); } - private void BrowseBase_Click(object sender, EventArgs e) - { - var f = new FolderBrowserDialog - { - Description = "Set the directory for the base global path", - SelectedPath = PathManager.MakeAbsolutePath(BasePathBox.Text, null) - }; - var result = f.ShowDialog(); - if (result == DialogResult.OK) - { - BasePathBox.Text = f.SelectedPath; - } - } - private void SpecialCommandsBtn_Click(object sender, EventArgs e) { new PathInfo().Show();