mirror of
https://github.com/Raymo111/i3lock-color.git
synced 2025-02-24 16:06:26 -05:00
Bugfix: Check for waiting X11 events before entering the event loop
This commit is contained in:
parent
cab5e6b1de
commit
34c8108c06
1 changed files with 4 additions and 1 deletions
5
i3lock.c
5
i3lock.c
|
@ -689,6 +689,9 @@ int main(int argc, char *argv[]) {
|
||||||
ev_prepare_init(xcb_prepare, xcb_prepare_cb);
|
ev_prepare_init(xcb_prepare, xcb_prepare_cb);
|
||||||
ev_prepare_start(main_loop, xcb_prepare);
|
ev_prepare_start(main_loop, xcb_prepare);
|
||||||
|
|
||||||
xcb_flush(conn);
|
/* Invoke the event callback once to catch all the events which were
|
||||||
|
* received up until now. ev will only pick up new events (when the X11
|
||||||
|
* file descriptor becomes readable). */
|
||||||
|
ev_invoke(main_loop, xcb_check, 0);
|
||||||
ev_loop(main_loop, 0);
|
ev_loop(main_loop, 0);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue