Skip to content

Commit 5789f15

Browse files
committed
Avoid setting the sidebar black
1 parent 16ea069 commit 5789f15

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

src/displayapp/screens/settings/SettingPineTimeStyle.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,8 @@ void SettingPineTimeStyle::UpdateSelected(lv_obj_t *object, lv_event_t event) {
252252
if((object == btnNextBar) && (event == LV_EVENT_PRESSED)) {
253253
if ( valueBar < 16 ) {
254254
valueBar += 1;
255+
// Avoid setting the sidebar black
256+
if ( valueBar == 3 ) { valueBar += 1; }
255257
} else {
256258
valueBar = 0;
257259
}
@@ -261,6 +263,8 @@ void SettingPineTimeStyle::UpdateSelected(lv_obj_t *object, lv_event_t event) {
261263
if((object == btnPrevBar) && (event == LV_EVENT_PRESSED)) {
262264
if ( valueBar > 0 ) {
263265
valueBar -= 1;
266+
// Avoid setting the sidebar black
267+
if ( valueBar == 3 ) { valueBar -= 1; }
264268
} else {
265269
valueBar = 16;
266270
}

0 commit comments

Comments
 (0)