Cheats Dialog - fix losing of values on restart, editing a cheat flags changes
This commit is contained in:
parent
d586876f40
commit
0e1bf887b6
|
@ -1401,6 +1401,7 @@ namespace BizHawk.MultiClient
|
||||||
Global.OSD.AddMessage("Cheats file loaded");
|
Global.OSD.AddMessage("Cheats file loaded");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Cheats1.UpdateValues();
|
||||||
|
|
||||||
CurrentlyOpenRom = file.CanonicalFullPath;
|
CurrentlyOpenRom = file.CanonicalFullPath;
|
||||||
HandlePlatformMenus();
|
HandlePlatformMenus();
|
||||||
|
|
|
@ -29,6 +29,7 @@ namespace BizHawk.MultiClient
|
||||||
NameBox.Text = "";
|
NameBox.Text = "";
|
||||||
AddressBox.Text = "";
|
AddressBox.Text = "";
|
||||||
ValueBox.Text = "";
|
ValueBox.Text = "";
|
||||||
|
CompareBox.Text = "";
|
||||||
PopulateMemoryDomainComboBox();
|
PopulateMemoryDomainComboBox();
|
||||||
AddressBox.MaxLength = GetNumDigits(Global.Emulator.MemoryDomains[0].Size - 1);
|
AddressBox.MaxLength = GetNumDigits(Global.Emulator.MemoryDomains[0].Size - 1);
|
||||||
}
|
}
|
||||||
|
@ -40,6 +41,14 @@ namespace BizHawk.MultiClient
|
||||||
ClearFields();
|
ClearFields();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void UpdateValues()
|
||||||
|
{
|
||||||
|
if (!this.IsHandleCreated || this.IsDisposed) return;
|
||||||
|
CheatListView.ItemCount = Global.CheatList.Count;
|
||||||
|
DisplayCheatsList();
|
||||||
|
CheatListView.Refresh();
|
||||||
|
}
|
||||||
|
|
||||||
public Cheats()
|
public Cheats()
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
|
@ -782,6 +791,7 @@ namespace BizHawk.MultiClient
|
||||||
{
|
{
|
||||||
Global.CheatList.Remove(Global.CheatList.Cheat(indexes[0]));
|
Global.CheatList.Remove(Global.CheatList.Cheat(indexes[0]));
|
||||||
Global.CheatList.Add(MakeCheat());
|
Global.CheatList.Add(MakeCheat());
|
||||||
|
Changes();
|
||||||
}
|
}
|
||||||
CheatListView.Refresh();
|
CheatListView.Refresh();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue