mirror of
https://github.com/swaywm/sway.git
synced 2026-03-30 11:10:59 -04:00
Handle swaybar status line errors
The event loop API was redesigned to avoid race conditions as well. Fixes #1583
This commit is contained in:
parent
6ffcb031f9
commit
a83bca6db5
5 changed files with 94 additions and 12 deletions
|
|
@ -13,11 +13,11 @@ void add_timer(timer_t timer,
|
|||
void(*cb)(timer_t timer, void *data),
|
||||
void *data);
|
||||
|
||||
// Returns false if nothing exists, true otherwise
|
||||
bool remove_event(int fd);
|
||||
// Remove the given event from the event loop
|
||||
void remove_event(int fd);
|
||||
|
||||
// Returns false if nothing exists, true otherwise
|
||||
bool remove_timer(timer_t timer);
|
||||
// Remove the given timer from the event loop
|
||||
void remove_timer(timer_t timer);
|
||||
|
||||
// Blocks and returns after sending callbacks
|
||||
void event_loop_poll();
|
||||
|
|
|
|||
|
|
@ -48,6 +48,12 @@ struct status_line *init_status_line();
|
|||
*/
|
||||
bool handle_status_line(struct bar *bar);
|
||||
|
||||
/**
|
||||
* This should be called if statusline input cannot be accessed.
|
||||
* It will set an error statusline instead of using the status command
|
||||
*/
|
||||
void handle_status_hup(struct status_line *status);
|
||||
|
||||
/**
|
||||
* Handle mouse clicks.
|
||||
*/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue