From f5d8b5e021a62bf3e36e18aa9aebee331fece8dd Mon Sep 17 00:00:00 2001 From: Lukas Fleischer Date: Thu, 25 Feb 2016 21:31:16 +0100 Subject: Support durations in recurrence ending dates When spending the end date of recurring items, allow date duration specifiers such as "+5d" or "+3w2d". Signed-off-by: Lukas Fleischer --- src/ui-calendar.c | 20 -------------------- 1 file changed, 20 deletions(-) (limited to 'src/ui-calendar.c') diff --git a/src/ui-calendar.c b/src/ui-calendar.c index 49ccdce..4f61376 100644 --- a/src/ui-calendar.c +++ b/src/ui-calendar.c @@ -256,26 +256,6 @@ static long ymd_to_scalar(unsigned year, unsigned month, unsigned day) return scalar; } -/* - * Used to change date by adding a certain amount of days or weeks. - * Returns 0 on success, 1 otherwise. - */ -static int date_change(struct tm *date, int delta_month, int delta_day) -{ - struct tm t; - - t = *date; - t.tm_mon += delta_month; - t.tm_mday += delta_day; - - if (mktime(&t) == -1) { - return 1; - } else { - *date = t; - return 0; - } -} - void ui_calendar_monthly_view_cache_set_invalid(void) { monthly_view_cache_valid = 0; -- cgit v1.2.3