From 39ab4665e6bb13372da24b86f32cc50fff8c0e9f Mon Sep 17 00:00:00 2001 From: Lars Henriksen Date: Tue, 28 Aug 2018 21:11:06 +0200 Subject: Data save and removal of the progress bar The function io_save_cal() saves apts, todos, configuration data and key bindings. The configuration and key files do not belong with the two data files, but the progress bar function assumes that all four files are saved in a fixed sequence. Since it is used nowhere else and contains unused parts, the function has been removed. A return code for file access error is introduced, and the EXIT macro moved to the command level in calcurse.c. Save of configuration and key data were already moved to the configuration menu in commit 0124618, A save refinement: no action if everything is unchanged. Signed-off-by: Lars Henriksen Signed-off-by: Lukas Fleischer --- src/calcurse.h | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'src/calcurse.h') diff --git a/src/calcurse.h b/src/calcurse.h index bec2a93..17c45f8 100644 --- a/src/calcurse.h +++ b/src/calcurse.h @@ -659,7 +659,8 @@ enum { IO_SAVE_CTINUE, IO_SAVE_RELOAD, IO_SAVE_CANCEL, - IO_SAVE_NOOP + IO_SAVE_NOOP, + IO_SAVE_ERROR }; /* Return codes for the io_reload_data() function. */ @@ -727,12 +728,6 @@ enum export_type { IO_EXPORT_NBTYPES }; -/* To customize the display when saving data. */ -enum save_display { - IO_SAVE_DISPLAY_BAR, - IO_SAVE_DISPLAY_NONE -}; - /* apoint.c */ extern llist_ts_t alist_p; void apoint_free_bkp(void); @@ -867,7 +862,7 @@ unsigned io_save_apts(const char *); void io_dump_todo(const char *); unsigned io_save_todo(const char *); unsigned io_save_keys(void); -int io_save_cal(enum save_display); +int io_save_cal(void); void io_load_app(struct item_filter *); void io_load_todo(struct item_filter *); int io_load_data(struct item_filter *, int); -- cgit v1.2.3-54-g00ecf