mirror of
https://github.com/JADE-Jerry/jcalendar.git
synced 2025-12-06 17:42:52 +08:00
Compare commits
2 Commits
3cbdda3c60
...
dabe760a81
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
dabe760a81 | ||
|
|
102b1b507f |
@@ -247,7 +247,9 @@ void draw_cal_days(bool partial) {
|
|||||||
totalDays = 31;
|
totalDays = 31;
|
||||||
}
|
}
|
||||||
if (monthNum == 2) {
|
if (monthNum == 2) {
|
||||||
if ((tmInfo.tm_year + 1900) == 0 && (tmInfo.tm_year + 1900) % 100 != 0) {
|
if ((tmInfo.tm_year + 1900) % 4 == 0
|
||||||
|
&& (tmInfo.tm_year + 1900) % 100 != 0
|
||||||
|
|| (tmInfo.tm_year + 1900) % 400 == 0){
|
||||||
totalDays = 29; // 闰二月
|
totalDays = 29; // 闰二月
|
||||||
} else {
|
} else {
|
||||||
totalDays = 28; // 二月
|
totalDays = 28; // 二月
|
||||||
@@ -936,4 +938,4 @@ void print_status() {
|
|||||||
Serial.printf("Weather: %d\n", weather_status());
|
Serial.printf("Weather: %d\n", weather_status());
|
||||||
Serial.printf("Calendar: %d\n", si_calendar_status());
|
Serial.printf("Calendar: %d\n", si_calendar_status());
|
||||||
Serial.printf("Screen: %d\n", si_screen_status());
|
Serial.printf("Screen: %d\n", si_screen_status());
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user