diff --git a/BizHawk.MultiClient/config/NewPathConfig.Designer.cs b/BizHawk.MultiClient/config/NewPathConfig.Designer.cs index d8cf44c70f..1ee29e268b 100644 --- a/BizHawk.MultiClient/config/NewPathConfig.Designer.cs +++ b/BizHawk.MultiClient/config/NewPathConfig.Designer.cs @@ -28,162 +28,162 @@ /// private void InitializeComponent() { - this.OK = new System.Windows.Forms.Button(); - this.Cancel = new System.Windows.Forms.Button(); - this.PathTabControl = new System.Windows.Forms.TabControl(); - this.SaveBtn = new System.Windows.Forms.Button(); - this.label1 = new System.Windows.Forms.Label(); - this.button1 = 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(); - // - // OK - // - this.OK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.OK.Location = new System.Drawing.Point(450, 411); - this.OK.Name = "OK"; - this.OK.Size = new System.Drawing.Size(75, 23); - this.OK.TabIndex = 0; - this.OK.Text = "&Ok"; - this.OK.UseVisualStyleBackColor = true; - this.OK.Click += new System.EventHandler(this.OK_Click); - // - // Cancel - // - this.Cancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.Cancel.DialogResult = System.Windows.Forms.DialogResult.Cancel; - this.Cancel.Location = new System.Drawing.Point(531, 411); - this.Cancel.Name = "Cancel"; - this.Cancel.Size = new System.Drawing.Size(75, 23); - this.Cancel.TabIndex = 1; - this.Cancel.Text = "&Cancel"; - this.Cancel.UseVisualStyleBackColor = true; - this.Cancel.Click += new System.EventHandler(this.Cancel_Click); - // - // PathTabControl - // - this.PathTabControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + this.OK = new System.Windows.Forms.Button(); + this.Cancel = new System.Windows.Forms.Button(); + this.PathTabControl = new System.Windows.Forms.TabControl(); + this.SaveBtn = new System.Windows.Forms.Button(); + this.label1 = new System.Windows.Forms.Label(); + this.button1 = 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(); + // + // OK + // + this.OK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.OK.Location = new System.Drawing.Point(471, 411); + this.OK.Name = "OK"; + this.OK.Size = new System.Drawing.Size(75, 23); + this.OK.TabIndex = 0; + this.OK.Text = "&Ok"; + this.OK.UseVisualStyleBackColor = true; + this.OK.Click += new System.EventHandler(this.OK_Click); + // + // Cancel + // + this.Cancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.Cancel.DialogResult = System.Windows.Forms.DialogResult.Cancel; + this.Cancel.Location = new System.Drawing.Point(552, 411); + this.Cancel.Name = "Cancel"; + this.Cancel.Size = new System.Drawing.Size(75, 23); + this.Cancel.TabIndex = 1; + this.Cancel.Text = "&Cancel"; + this.Cancel.UseVisualStyleBackColor = true; + this.Cancel.Click += new System.EventHandler(this.Cancel_Click); + // + // 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.Multiline = true; - this.PathTabControl.Name = "PathTabControl"; - this.PathTabControl.SelectedIndex = 0; - this.PathTabControl.Size = new System.Drawing.Size(594, 321); - this.PathTabControl.TabIndex = 2; - // - // SaveBtn - // - this.SaveBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); - this.SaveBtn.Location = new System.Drawing.Point(12, 411); - this.SaveBtn.Name = "SaveBtn"; - this.SaveBtn.Size = new System.Drawing.Size(75, 23); - this.SaveBtn.TabIndex = 3; - this.SaveBtn.Text = "&Save"; - this.SaveBtn.UseVisualStyleBackColor = true; - this.SaveBtn.Click += new System.EventHandler(this.SaveBtn_Click); - // - // label1 - // - 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(506, 52); - this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(97, 13); - this.label1.TabIndex = 210; - this.label1.Text = "Special Commands"; - // - // button1 - // - this.button1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.button1.Image = global::BizHawk.MultiClient.Properties.Resources.Help; - this.button1.Location = new System.Drawing.Point(475, 47); - this.button1.Name = "button1"; - this.button1.Size = new System.Drawing.Size(26, 23); - this.button1.TabIndex = 209; - this.button1.UseVisualStyleBackColor = true; - this.button1.Click += new System.EventHandler(this.button1_Click); - // - // RecentForROMs - // - this.RecentForROMs.AutoSize = true; - this.RecentForROMs.Location = new System.Drawing.Point(12, 51); - this.RecentForROMs.Name = "RecentForROMs"; - this.RecentForROMs.Size = new System.Drawing.Size(184, 17); - this.RecentForROMs.TabIndex = 207; - this.RecentForROMs.Text = "Always use recent path for ROMs"; - 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) + this.PathTabControl.Location = new System.Drawing.Point(12, 84); + this.PathTabControl.Multiline = true; + this.PathTabControl.Name = "PathTabControl"; + this.PathTabControl.SelectedIndex = 0; + this.PathTabControl.Size = new System.Drawing.Size(615, 321); + this.PathTabControl.TabIndex = 2; + // + // SaveBtn + // + this.SaveBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left))); + this.SaveBtn.Location = new System.Drawing.Point(12, 411); + this.SaveBtn.Name = "SaveBtn"; + this.SaveBtn.Size = new System.Drawing.Size(75, 23); + this.SaveBtn.TabIndex = 3; + this.SaveBtn.Text = "&Save"; + this.SaveBtn.UseVisualStyleBackColor = true; + this.SaveBtn.Click += new System.EventHandler(this.SaveBtn_Click); + // + // label1 + // + 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.Name = "label1"; + this.label1.Size = new System.Drawing.Size(97, 13); + this.label1.TabIndex = 210; + this.label1.Text = "Special Commands"; + // + // button1 + // + this.button1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.button1.Image = global::BizHawk.MultiClient.Properties.Resources.Help; + this.button1.Location = new System.Drawing.Point(496, 47); + this.button1.Name = "button1"; + this.button1.Size = new System.Drawing.Size(26, 23); + this.button1.TabIndex = 209; + this.button1.UseVisualStyleBackColor = true; + this.button1.Click += new System.EventHandler(this.button1_Click); + // + // RecentForROMs + // + this.RecentForROMs.AutoSize = true; + this.RecentForROMs.Location = new System.Drawing.Point(12, 51); + this.RecentForROMs.Name = "RecentForROMs"; + this.RecentForROMs.Size = new System.Drawing.Size(184, 17); + this.RecentForROMs.TabIndex = 207; + this.RecentForROMs.Text = "Always use recent path for ROMs"; + 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(489, 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.MultiClient.Properties.Resources.OpenFile; - this.BrowseBase.Location = new System.Drawing.Point(509, 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(542, 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.Location = new System.Drawing.Point(93, 411); - this.DefaultsBtn.Name = "DefaultsBtn"; - this.DefaultsBtn.Size = new System.Drawing.Size(75, 23); - this.DefaultsBtn.TabIndex = 211; - this.DefaultsBtn.Text = "&Defaults"; - this.DefaultsBtn.UseVisualStyleBackColor = true; - this.DefaultsBtn.Click += new System.EventHandler(this.DefaultsBtn_Click); - // - // NewPathConfig - // - this.AcceptButton = this.OK; - this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); - this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.CancelButton = this.Cancel; - this.ClientSize = new System.Drawing.Size(618, 446); - this.Controls.Add(this.DefaultsBtn); - this.Controls.Add(this.label1); - this.Controls.Add(this.button1); - 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); - this.Controls.Add(this.OK); - this.MinimumSize = new System.Drawing.Size(360, 250); - this.Name = "NewPathConfig"; - this.ShowIcon = false; - this.Text = "Path Configuration"; - this.Load += new System.EventHandler(this.NewPathConfig_Load); - this.ResumeLayout(false); - this.PerformLayout(); + 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.MultiClient.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.Location = new System.Drawing.Point(93, 411); + this.DefaultsBtn.Name = "DefaultsBtn"; + this.DefaultsBtn.Size = new System.Drawing.Size(75, 23); + this.DefaultsBtn.TabIndex = 211; + this.DefaultsBtn.Text = "&Defaults"; + this.DefaultsBtn.UseVisualStyleBackColor = true; + this.DefaultsBtn.Click += new System.EventHandler(this.DefaultsBtn_Click); + // + // NewPathConfig + // + this.AcceptButton = this.OK; + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.CancelButton = this.Cancel; + this.ClientSize = new System.Drawing.Size(639, 446); + this.Controls.Add(this.DefaultsBtn); + this.Controls.Add(this.label1); + this.Controls.Add(this.button1); + 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); + this.Controls.Add(this.OK); + this.MinimumSize = new System.Drawing.Size(360, 250); + this.Name = "NewPathConfig"; + this.ShowIcon = false; + this.Text = "Path Configuration"; + this.Load += new System.EventHandler(this.NewPathConfig_Load); + this.ResumeLayout(false); + this.PerformLayout(); } diff --git a/BizHawk.MultiClient/config/NewPathConfig.cs b/BizHawk.MultiClient/config/NewPathConfig.cs index 930d9a8323..037aa7eab6 100644 --- a/BizHawk.MultiClient/config/NewPathConfig.cs +++ b/BizHawk.MultiClient/config/NewPathConfig.cs @@ -11,6 +11,20 @@ namespace BizHawk.MultiClient { public partial class NewPathConfig : Form { + private void LockDownCores() + { + if (!MainForm.INTERIM) + { + string[] coresToHide = { "PSX", "GBA", "INTV", "C64", "GEN" }; + + foreach(string core in coresToHide) + { + TabPage tp = AllTabPages.FirstOrDefault(x => x.Name == core); + PathTabControl.TabPages.Remove(tp); + } + } + } + private AutoCompleteStringCollection AutoCompleteOptions { get @@ -33,6 +47,7 @@ namespace BizHawk.MultiClient private void NewPathConfig_Load(object sender, EventArgs e) { LoadSettings(); + LockDownCores(); } private void OK_Click(object sender, EventArgs e) @@ -119,7 +134,7 @@ namespace BizHawk.MultiClient { TabPage t = new TabPage() { - Text = systemId, + Text = systemId == "SG" ? "SG-1000" : systemId == "GEN" ? "Genesis" : systemId, //TODO: don't be hacky Name = systemId, }; List paths = PathCollection.Where(x => x.System == systemId).OrderBy(x => x.Ordinal).ThenBy(x => x.Type).ToList(); @@ -330,6 +345,19 @@ namespace BizHawk.MultiClient } } + private List AllTabPages + { + get + { + List _AllTabPages = new List(); + foreach (TabPage tp in PathTabControl.TabPages) + { + _AllTabPages.Add(tp); + } + return _AllTabPages; + } + } + private void DefaultsBtn_Click(object sender, EventArgs e) { DoTabs(PathEntryCollection.DefaultValues);