aboutsummaryrefslogtreecommitdiffstats
path: root/src/displayapp/screens/CheckboxList.cpp
diff options
context:
space:
mode:
authorJean-François Milants <jf@codingfield.com>2022-09-11 20:18:01 +0200
committerJean-François Milants <jf@codingfield.com>2022-09-11 20:18:01 +0200
commit58bb0e77db34703b99522956de804a674ec81a23 (patch)
treed5565d353c750af57cd739494f852b52fe3f12bd /src/displayapp/screens/CheckboxList.cpp
parent970d5b368d9d651a451435b9882720124566fcb9 (diff)
Fix formatting
Diffstat (limited to 'src/displayapp/screens/CheckboxList.cpp')
-rw-r--r--src/displayapp/screens/CheckboxList.cpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/displayapp/screens/CheckboxList.cpp b/src/displayapp/screens/CheckboxList.cpp
index 4da7826c..177a9718 100644
--- a/src/displayapp/screens/CheckboxList.cpp
+++ b/src/displayapp/screens/CheckboxList.cpp
@@ -1,7 +1,6 @@
#include "displayapp/screens/CheckboxList.h"
#include "displayapp/DisplayApp.h"
#include "displayapp/screens/Styles.h"
-#include "displayapp/screens/Symbols.h"
using namespace Pinetime::Applications::Screens;
@@ -20,10 +19,13 @@ CheckboxList::CheckboxList(const uint8_t screenID,
const char* optionsTitle,
const char* optionsSymbol,
void (Controllers::Settings::*SetOptionIndex)(uint8_t),
- uint8_t (Controllers::Settings::*GetOptionIndex )() const,
+ uint8_t (Controllers::Settings::*GetOptionIndex)() const,
std::array<const char*, MAXLISTITEMS> options)
- : Screen(app), screenID {screenID}, settingsController {settingsController},
- SetOptionIndex {SetOptionIndex}, GetOptionIndex {GetOptionIndex},
+ : Screen(app),
+ screenID {screenID},
+ settingsController {settingsController},
+ SetOptionIndex {SetOptionIndex},
+ GetOptionIndex {GetOptionIndex},
options {options} {
settingsController.SetWatchfacesMenu(screenID);
@@ -87,7 +89,7 @@ CheckboxList::CheckboxList(const uint8_t screenID,
lv_obj_set_event_cb(cbOption[i], event_handler);
SetRadioButtonStyle(cbOption[i]);
- if (static_cast<unsigned int>((settingsController.*GetOptionIndex)() - MAXLISTITEMS*screenID) == i) {
+ if (static_cast<unsigned int>((settingsController.*GetOptionIndex)() - MAXLISTITEMS * screenID) == i) {
lv_checkbox_set_checked(cbOption[i], true);
}
}
@@ -105,7 +107,7 @@ void CheckboxList::UpdateSelected(lv_obj_t* object, lv_event_t event) {
if (strcmp(options[i], "")) {
if (object == cbOption[i]) {
lv_checkbox_set_checked(cbOption[i], true);
- (settingsController.*SetOptionIndex)(MAXLISTITEMS*screenID + i);
+ (settingsController.*SetOptionIndex)(MAXLISTITEMS * screenID + i);
} else {
lv_checkbox_set_checked(cbOption[i], false);
}