mirror of
https://github.com/rust-windowing/winit.git
synced 2026-06-26 22:53:15 -04:00
Use XSetEventQueueOwner to indicate XCB
I don't know what this actually does, but it can't hurt, right? Signed-off-by: John Nunley <dev@notgull.net>
This commit is contained in:
@@ -91,6 +91,14 @@ impl XConnection {
|
||||
conn.map_err(|e| XNotSupported::XcbConversionError(Arc::new(WrapConnectError(e))))?
|
||||
};
|
||||
|
||||
// Make sure Xlib knows XCB is handling events.
|
||||
unsafe {
|
||||
(xlib_xcb.XSetEventQueueOwner)(
|
||||
display,
|
||||
x11_dl::xlib_xcb::XEventQueueOwner::XCBOwnsEventQueue,
|
||||
);
|
||||
}
|
||||
|
||||
// Get the default screen.
|
||||
let default_screen = unsafe { (xlib.XDefaultScreen)(display) } as usize;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user