From dbc838565cd70ff4702991b407f54387dc84e3e1 Mon Sep 17 00:00:00 2001 From: "Unknown W. Brackets" Date: Sat, 11 Apr 2020 12:59:06 -0700 Subject: [PATCH] UI: Cleanup old specialized checkbox. --- UI/CwCheatScreen.cpp | 2 +- UI/CwCheatScreen.h | 14 -------------- 2 files changed, 1 insertion(+), 15 deletions(-) diff --git a/UI/CwCheatScreen.cpp b/UI/CwCheatScreen.cpp index fb6608b3b2..a1559d24af 100644 --- a/UI/CwCheatScreen.cpp +++ b/UI/CwCheatScreen.cpp @@ -91,7 +91,7 @@ void CwCheatScreen::CreateViews() { rightColumn->Add(new ItemHeader(cw->T("Cheats"))); for (size_t i = 0; i < fileInfo_.size(); ++i) { - rightColumn->Add(new CheatCheckBox(&fileInfo_[i].enabled, fileInfo_[i].name))->OnClick.Add([=](UI::EventParams &) { + rightColumn->Add(new CheckBox(&fileInfo_[i].enabled, fileInfo_[i].name))->OnClick.Add([=](UI::EventParams &) { return OnCheckBox((int)i); }); } diff --git a/UI/CwCheatScreen.h b/UI/CwCheatScreen.h index 3417204218..860fb8f864 100644 --- a/UI/CwCheatScreen.h +++ b/UI/CwCheatScreen.h @@ -58,17 +58,3 @@ private: uint64_t fileCheckHash_; bool enableAllFlag_ = false; }; - -class CheatCheckBox : public UI::CheckBox { -public: - CheatCheckBox(bool *toggle, const std::string &text, UI::LayoutParams *layoutParams = nullptr) - : UI::CheckBox(toggle, text, "", layoutParams), text_(text) { - } - - std::string Text() { - return text_; - } - -private: - std::string text_; -};