Lock screen when drawing on the calendar/notification panel

Lock the screen if either the calendar panel or the notification bar is
updated to avoid race conditions.

Addresses BUG#6.

Note that we currently always use a screen-level lock, even if only one
window is affected. This is to be changed in the future.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
This commit is contained in:
Lukas Fleischer
2012-11-23 09:59:06 +01:00
parent e16ac0a8a8
commit a80f8dcf2c
4 changed files with 61 additions and 3 deletions

View File

@@ -975,6 +975,10 @@ void vars_init(void);
/* wins.c */
extern struct window win[NBWINS];
unsigned wins_nbar_lock(void);
void wins_nbar_unlock(void);
unsigned wins_calendar_lock(void);
void wins_calendar_unlock(void);
int wins_refresh(void);
int wins_wrefresh(WINDOW *);
int wins_doupdate(void);