Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge pull request #127 from lioncash/cheat-dlg-simplification
Make the base calculation in CheatsWindow simpler.
  • Loading branch information
delroth committed Mar 3, 2014
2 parents bd99e4a + 10f3d90 commit 32e0544
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Source/Core/DolphinWX/CheatsWindow.cpp
Expand Up @@ -647,7 +647,8 @@ void CreateCodeDialog::PressOK(wxCommandEvent& ev)
}

long code_value;
if (!textctrl_value->GetValue().ToLong(&code_value, 10 + checkbox_use_hex->GetValue()*6))
int base = checkbox_use_hex->IsChecked() ? 16 : 10;
if (!textctrl_value->GetValue().ToLong(&code_value, base))
{
PanicAlertT("Invalid Value!");
return;
Expand Down

0 comments on commit 32e0544

Please sign in to comment.