Skip to content

Commit

Permalink
UI: allow editing cheat file on any Unix desktop
Browse files Browse the repository at this point in the history
  • Loading branch information
jbeich committed May 26, 2015
1 parent 0af2bfe commit bd4b084
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions UI/CwCheatScreen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ void CwCheatScreen::CreateViews() {
leftColumn->Add(new Choice(d->T("Back")))->OnClick.Handle<UIScreen>(this, &UIScreen::OnBack);
//leftColumn->Add(new Choice(k->T("Add Cheat")))->OnClick.Handle(this, &CwCheatScreen::OnAddCheat);
leftColumn->Add(new Choice(k->T("Import Cheats")))->OnClick.Handle(this, &CwCheatScreen::OnImportCheat);
#if defined(_WIN32) || defined(__APPLE__) || defined(__linux__)
#if !defined(MOBILE_DEVICE)
leftColumn->Add(new Choice(k->T("Edit Cheat File")))->OnClick.Handle(this, &CwCheatScreen::OnEditCheatFile);
#endif
leftColumn->Add(new Choice(k->T("Enable/Disable All")))->OnClick.Handle(this, &CwCheatScreen::OnEnableAll);
Expand Down Expand Up @@ -180,11 +180,11 @@ UI::EventReturn CwCheatScreen::OnEditCheatFile(UI::EventParams &params) {
if (!retval) {
ERROR_LOG(COMMON, "Failed creating notepad process");
}
#elif defined(__APPLE__) || defined(__linux__)
#if defined(__linux__)
cheatFile = "xdg-open ";
#elif defined(__APPLE__)
#elif !defined(MOBILE_DEVICE)
#if defined(__APPLE__)
cheatFile = "open ";
#else
cheatFile = "xdg-open ";
#endif
cheatFile.append(activeCheatFile);
NOTICE_LOG(BOOT, "Launching %s", cheatFile.c_str());
Expand Down

0 comments on commit bd4b084

Please sign in to comment.