From 3a75d76001aaaa5a82fc9891bfca769fa8390553 Mon Sep 17 00:00:00 2001 From: Marcel Hollerbach Date: Tue, 31 Dec 2019 09:59:41 +0100 Subject: [PATCH] efl_ui_datepicker: do not substract anything fom mday out of the documentation of struct tm: int tm_mday; /* Day. [1-31] */ shifting this range one up results in day 32 beeing selectable, but 1 not beeing selectable. With this commit we could have again working CI. Differential Revision: https://phab.enlightenment.org/D10992 --- src/lib/elementary/efl_ui_datepicker.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib/elementary/efl_ui_datepicker.c b/src/lib/elementary/efl_ui_datepicker.c index c52c43437f..78427ac21e 100644 --- a/src/lib/elementary/efl_ui_datepicker.c +++ b/src/lib/elementary/efl_ui_datepicker.c @@ -18,7 +18,7 @@ Efl_Time t = efl_datetime_manager_value_get(pd->dt_manager); \ pd->cur_date[DATEPICKER_YEAR] = t.tm_year + 1900; \ pd->cur_date[DATEPICKER_MONTH] = t.tm_mon + 1; \ - pd->cur_date[DATEPICKER_DAY] = t.tm_mday + 1; \ + pd->cur_date[DATEPICKER_DAY] = t.tm_mday; \ } while (0) #define DATE_SET() \ @@ -26,7 +26,7 @@ Efl_Time t = { 0 }; \ t.tm_year = pd->cur_date[DATEPICKER_YEAR] - 1900; \ t.tm_mon = pd->cur_date[DATEPICKER_MONTH] - 1; \ - t.tm_mday = pd->cur_date[DATEPICKER_DAY] - 1; \ + t.tm_mday = pd->cur_date[DATEPICKER_DAY]; \ t.tm_sec = 0; \ efl_datetime_manager_value_set(pd->dt_manager, t); \ } while (0)