From 7b25254b72ebc618776828969a0bdd45b3980c77 Mon Sep 17 00:00:00 2001 From: scrimpeh Date: Wed, 15 Jul 2015 08:31:03 +0200 Subject: [PATCH] Firmware Manager - Change wording to "Close and reload ROM" instead of "Close and load ROM", add tool tip displaying ROM path. --- BizHawk.Client.EmuHawk/MainForm.Events.cs | 4 ++-- .../config/FirmwaresConfig.Designer.cs | 4 ++-- BizHawk.Client.EmuHawk/config/FirmwaresConfig.cs | 15 ++++++++++++--- 3 files changed, 16 insertions(+), 7 deletions(-) diff --git a/BizHawk.Client.EmuHawk/MainForm.Events.cs b/BizHawk.Client.EmuHawk/MainForm.Events.cs index 780d5878c8..11997e997d 100644 --- a/BizHawk.Client.EmuHawk/MainForm.Events.cs +++ b/BizHawk.Client.EmuHawk/MainForm.Events.cs @@ -883,8 +883,8 @@ namespace BizHawk.Client.EmuHawk if (e is RomLoader.RomErrorArgs) { var args = e as RomLoader.RomErrorArgs; - var firmwaredialog = new FirmwaresConfig(true).ShowDialog(); - args.Retry = firmwaredialog == DialogResult.Retry; + var result = new FirmwaresConfig(true, args.RomPath).ShowDialog(); + args.Retry = result == DialogResult.Retry; } else { diff --git a/BizHawk.Client.EmuHawk/config/FirmwaresConfig.Designer.cs b/BizHawk.Client.EmuHawk/config/FirmwaresConfig.Designer.cs index 332e2f0f91..96816028b1 100644 --- a/BizHawk.Client.EmuHawk/config/FirmwaresConfig.Designer.cs +++ b/BizHawk.Client.EmuHawk/config/FirmwaresConfig.Designer.cs @@ -282,8 +282,8 @@ this.tbbCloseReload.Image = ((System.Drawing.Image)(resources.GetObject("tbbCloseReload.Image"))); this.tbbCloseReload.ImageTransparentColor = System.Drawing.Color.Magenta; this.tbbCloseReload.Name = "tbbCloseReload"; - this.tbbCloseReload.Size = new System.Drawing.Size(119, 22); - this.tbbCloseReload.Text = "Close and load ROM"; + this.tbbCloseReload.Size = new System.Drawing.Size(129, 22); + this.tbbCloseReload.Text = "Close and reload ROM"; this.tbbCloseReload.ToolTipText = "Close and reload ROM"; this.tbbCloseReload.Visible = false; this.tbbCloseReload.Click += new System.EventHandler(this.tbbCloseReload_Click); diff --git a/BizHawk.Client.EmuHawk/config/FirmwaresConfig.cs b/BizHawk.Client.EmuHawk/config/FirmwaresConfig.cs index 39d976e832..acaa8cec40 100644 --- a/BizHawk.Client.EmuHawk/config/FirmwaresConfig.cs +++ b/BizHawk.Client.EmuHawk/config/FirmwaresConfig.cs @@ -57,8 +57,6 @@ namespace BizHawk.Client.EmuHawk private const int idMissing = 1; private const int idOk = 2; - RomLoader.RomErrorArgs RomErrorArgs; - Font fixedFont, boldFont, boldFixedFont; class ListViewSorter : IComparer @@ -82,7 +80,7 @@ namespace BizHawk.Client.EmuHawk string currSelectorDir; ListViewSorter listviewSorter; - public FirmwaresConfig(bool retryLoadRom = false) + public FirmwaresConfig(bool retryLoadRom = false, string reloadRomPath = null) { InitializeComponent(); @@ -96,6 +94,17 @@ namespace BizHawk.Client.EmuHawk toolStripSeparator1.Visible = true; tbbCloseReload.Visible = true; tbbCloseReload.Enabled = true; + + + if (string.IsNullOrWhiteSpace(reloadRomPath)) + { + tbbCloseReload.ToolTipText = "Close Firmware Manager and reload ROM"; + } + else + { + tbbCloseReload.ToolTipText = "Close Firmware Manager and reload " + reloadRomPath; + } + } }