diff options
author | Lars Henriksen <LarsHenriksen@get2net.dk> | 2018-09-15 17:56:03 +0200 |
---|---|---|
committer | Lukas Fleischer <lfleischer@calcurse.org> | 2018-10-21 20:02:57 +0200 |
commit | 53b55930e8021f28a5393896b29b6a01d81cadd3 (patch) | |
tree | 4491572b16b9705b5e5a4f78b3f5518835ecdd9c /src/custom.c | |
parent | 3d93ffa7ca7918034ec485fcd7c30b5e6cfe217d (diff) | |
download | calcurse-53b55930e8021f28a5393896b29b6a01d81cadd3.tar.gz calcurse-53b55930e8021f28a5393896b29b6a01d81cadd3.zip |
Configuration variable for system events
After user acknowledgement a system event is deleted from the event queue.
The configuration variable determines whether it is turned into an appointment
(for later inspection) or not.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
Diffstat (limited to 'src/custom.c')
-rw-r--r-- | src/custom.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/custom.c b/src/custom.c index cf1cce5..df5c174 100644 --- a/src/custom.c +++ b/src/custom.c @@ -529,6 +529,7 @@ enum { AUTO_SAVE, AUTO_GC, PERIODIC_SAVE, + SYSTEM_EVENTS, CONFIRM_QUIT, CONFIRM_DELETE, SYSTEM_DIAGS, @@ -550,6 +551,7 @@ static void print_general_option(int i, WINDOW *win, int y, int hilt, void *cb_d "general.autosave = ", "general.autogc = ", "general.periodicsave = ", + "general.systemevents = ", "general.confirmquit = ", "general.confirmdelete = ", "general.systemdialogs = ", @@ -607,6 +609,12 @@ static void print_general_option(int i, WINDOW *win, int y, int hilt, void *cb_d _("(if not null, automatically save data every 'periodic_save' " "minutes)")); break; + case SYSTEM_EVENTS: + print_bool_option_incolor(win, conf.systemevents, y, + XPOS + strlen(opt[SYSTEM_EVENTS])); + mvwaddstr(win, y + 1, XPOS, + _("(if YES, system events are turned into appointments (or else deleted))")); + break; case CONFIRM_QUIT: print_bool_option_incolor(win, conf.confirm_quit, y, XPOS + strlen(opt[CONFIRM_QUIT])); @@ -743,6 +751,9 @@ static void general_option_edit(int i) } } break; + case SYSTEM_EVENTS: + conf.systemevents = !conf.systemevents; + break; case CONFIRM_QUIT: conf.confirm_quit = !conf.confirm_quit; break; |