Revert "Ctrl+A support in the action replay code editing menu."

Guess it wasnt much of a solution as I'd hoped. (considering it seems to work on linux without this).

This reverts commit 0c1ea605d5.
This commit is contained in:
Lioncash 2013-01-21 00:11:53 -05:00
parent 0c1ea605d5
commit 2bae4345c5
2 changed files with 0 additions and 25 deletions

View File

@ -48,13 +48,11 @@ CARCodeAddEdit::CARCodeAddEdit(int _selection, wxWindow* parent, wxWindowID id,
wxStaticText* EditCheatNameText = new wxStaticText(this, ID_EDITCHEAT_NAME_TEXT, _("Name:"), wxDefaultPosition, wxDefaultSize);
EditCheatName = new wxTextCtrl(this, ID_EDITCHEAT_NAME, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0);
EditCheatName->Bind(wxEVT_KEY_DOWN, &CARCodeAddEdit::OnKey, this);
EditCheatName->SetValue(currentName);
EntrySelection = new wxSpinButton(this, ID_ENTRY_SELECT, wxDefaultPosition, wxDefaultSize, wxVERTICAL);
EntrySelection->SetRange(1, ((int)arCodes.size()) > 0 ? (int)arCodes.size() : 1);
EntrySelection->SetValue((int)(arCodes.size() - selection));
EditCheatCode = new wxTextCtrl(this, ID_EDITCHEAT_CODE, wxEmptyString, wxDefaultPosition, wxSize(300, 100), wxTE_MULTILINE);
EditCheatCode->Bind(wxEVT_KEY_DOWN, &CARCodeAddEdit::OnKey, this);
UpdateTextCtrl(tempEntries);
sgEntry->Add(EditCheatNameText, wxGBPosition(0, 0), wxGBSpan(1, 1), wxALIGN_CENTER|wxALL, 5);
@ -176,25 +174,3 @@ void CARCodeAddEdit::UpdateTextCtrl(ActionReplay::ARCode arCode)
else
EditCheatCode->SetValue(_("Insert Encrypted or Decrypted code here..."));
}
void CARCodeAddEdit::OnKey(wxKeyEvent& event)
{
// Technically you can extend this to whatever bindings you want.
switch (event.GetKeyCode())
{
case 'a':
case 'A':
{
if (event.ControlDown() && FindFocus() == EditCheatCode)
{
EditCheatCode->SetSelection(0, EditCheatCode->GetValue().Length());
}
if (event.ControlDown() && FindFocus() == EditCheatName)
{
EditCheatName->SetSelection(0, EditCheatName->GetValue().Length());
}
}
break;
}
}

View File

@ -49,7 +49,6 @@ class CARCodeAddEdit : public wxDialog
void SaveCheatData(wxCommandEvent& event);
void ChangeEntry(wxSpinEvent& event);
void UpdateTextCtrl(ActionReplay::ARCode arCode);
void OnKey(wxKeyEvent& event);
int selection;