smithay icon indicating copy to clipboard operation
smithay copied to clipboard

Expose properties of Winit*Event

Open egasimus opened this issue 3 years ago • 3 comments

Just changing from pub(crate) to pub to allow these structs to be created from outside the crate.

This enabled me to write an alternate winit backend which shares the winit event loop between multiple windows. So far it renders a background and receives events from each window; I'm currently putting the XWayland module back together and then I'll try to get multiple views into the same screenspace from winit and then try again to port my compositor to the udev backend through this Engine trait.

egasimus avatar Jan 08 '23 21:01 egasimus

Links which you provided leads to private repo also from the talk on matrix, winit will be replaced with pure backends for both, X11 and Wayland because it doesn't play well with Compositor's event loop.

heavyrain266 avatar Jan 08 '23 21:01 heavyrain266

See also: https://github.com/Smithay/smithay/discussions/858

egasimus avatar Jan 11 '23 20:01 egasimus

Tbh, there is a reason these are not exposed by default, because the contents of these events is not part of the public api.

I would rather like to see a modification of the winit-Backend, that allows to create a new WinitGraphicsBackend from an existing WinitEventLoop basically breaking apart the init-methods, which always return both.

Drakulix avatar Jan 12 '23 17:01 Drakulix