ISOProperties: Add notification when Cheats are disabled.

If the user enables a cheat while cheats are globally disabled then
display a notice about it. Issue 9690.
This commit is contained in:
EmptyChaos
2016-07-23 01:05:22 +00:00
parent 00a4404045
commit cf0b4c9387
6 changed files with 174 additions and 16 deletions

View File

@ -23,6 +23,8 @@
#include "DolphinWX/Cheats/GeckoCodeDiag.h"
#include "DolphinWX/WxUtils.h"
wxDEFINE_EVENT(DOLPHIN_EVT_GECKOCODE_TOGGLED, wxCommandEvent);
namespace Gecko
{
static const wxString wxstr_name(wxTRANSLATE("Name: ")), wxstr_notes(wxTRANSLATE("Notes: ")),
@ -108,7 +110,13 @@ void CodeConfigPanel::ToggleCode(wxCommandEvent& evt)
{
const int sel = evt.GetInt(); // this right?
if (sel > -1)
{
m_gcodes[sel].enabled = m_listbox_gcodes->IsChecked(sel);
wxCommandEvent toggle_event(DOLPHIN_EVT_GECKOCODE_TOGGLED, GetId());
toggle_event.SetClientData(&m_gcodes[sel]);
GetEventHandler()->ProcessEvent(toggle_event);
}
}
void CodeConfigPanel::UpdateInfoBox(wxCommandEvent&)