Simplify day storage
The function day_process_storage() is a wrapper for day_store_items(). It has an unused second argument, and is only used twice to load the selected day. It has been removed. A new function, get_slctd_day(), is the equivalant of get_today() and replaces the very awkwardly named ui_calendar_get_slctd_day_sec(). Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
This commit is contained in:
committed by
Lukas Fleischer
parent
06a4449afa
commit
8dd694b569
@@ -672,6 +672,12 @@ time_t get_today(void)
|
||||
return date2sec(day, 0, 0);
|
||||
}
|
||||
|
||||
/* Returns the beginning of the selected day in the calendar. */
|
||||
time_t get_slctd_day(void)
|
||||
{
|
||||
return date2sec(*ui_calendar_get_slctd_day(), 0, 0);
|
||||
}
|
||||
|
||||
/* Returns the current time in seconds. */
|
||||
time_t now(void)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user