Change the Settings toggle to a specially styled checkbox

This commit is contained in:
Henrik Rydgård committed 2022-12-07 11:12:29 +01:00
1 parent 59c4ff6af4
commit 241dd4093b
5 files changed
+79 -20

No files matched your search

+2 -2
View File
@@ -310,9 +310,9 @@ void DisplayLayoutScreen::CreateViews() {
}
}
if (hasSettings) {
auto settingsButton = shaderRow->Add(new Choice(ImageID("I_SLIDERS"), new LinearLayoutParams(0.0f)));
CheckBox *checkBox = new CheckBox(&settingsVisible_[i], ImageID("I_SLIDERS"), new LinearLayoutParams(0.0f));
auto settingsButton = shaderRow->Add(checkBox);
settingsButton->OnClick.Add([=](EventParams &e) {
settingsVisible_[i] = !settingsVisible_[i];
RecreateViews();
return UI::EVENT_DONE;
});