From 9826e26a4ba2a4e8b3cdfb2ba335ca4dad81f3cb Mon Sep 17 00:00:00 2001 From: "andres.delikat" Date: Sat, 6 Aug 2011 19:49:21 +0000 Subject: [PATCH] Cheats - fix the adding of a cheat from another dialog (Ram Watch/Search, Hex Editor, etc) --- BizHawk.MultiClient/tools/Cheat.cs | 9 +++++++-- BizHawk.MultiClient/tools/Cheats.cs | 1 - 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/BizHawk.MultiClient/tools/Cheat.cs b/BizHawk.MultiClient/tools/Cheat.cs index 308136b5c7..fa8d4a775c 100644 --- a/BizHawk.MultiClient/tools/Cheat.cs +++ b/BizHawk.MultiClient/tools/Cheat.cs @@ -27,6 +27,9 @@ namespace BizHawk.MultiClient value = c.value; enabled = c.enabled; domain = c.domain; + if (enabled) + MemoryPulse.Add(domain, address, value); + } public Cheat(string cname, int addr, byte val, bool e, MemoryDomain d) @@ -36,18 +39,20 @@ namespace BizHawk.MultiClient value = val; enabled = e; domain = d; + if (enabled) + MemoryPulse.Add(domain, address, value); } public void Enable() { enabled = true; - MemoryPulse.Add(domain, address, value); + MemoryPulse.Add(domain, address, value); } public void Disable() { enabled = false; - MemoryPulse.Remove(domain, address); + MemoryPulse.Remove(domain, address); } public bool IsEnabled() diff --git a/BizHawk.MultiClient/tools/Cheats.cs b/BizHawk.MultiClient/tools/Cheats.cs index cace6af287..eeeba179db 100644 --- a/BizHawk.MultiClient/tools/Cheats.cs +++ b/BizHawk.MultiClient/tools/Cheats.cs @@ -14,7 +14,6 @@ namespace BizHawk.MultiClient public partial class Cheats : Form { //Implement Freeze functions in all memory domains - //Restore Window Size should restore column order as well //context menu - enable/disable highlight dependent items int defaultWidth; //For saving the default size of the dialog, so the user can restore if desired