Readds leap year checks (#2)
This commit is contained in:
@@ -64,13 +64,11 @@ static void _day_one_face_increment(day_one_state_t *state) {
|
||||
state->birth_month = (state->birth_month % 12) + 1;
|
||||
break;
|
||||
case PAGE_DAY:
|
||||
state->birth_day = state->birth_day + 1;
|
||||
state->birth_day = (state->birth_day % watch_utility_days_in_month(state->birth_month, state->birth_year)) + 1;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
if (state->birth_day == 0 || state->birth_day > days_in_month(state->birth_month, state->birth_year))
|
||||
state->birth_day = 1;
|
||||
}
|
||||
|
||||
void day_one_face_setup(uint8_t watch_face_index, void ** context_ptr) {
|
||||
|
||||
Reference in New Issue
Block a user