@@ -45,6 +45,8 @@ mod frame;
4545use frame:: { idle_after, render_frame, step} ;
4646#[ path = "overlay/placement.rs" ]
4747mod placement;
48+ #[ path = "overlay/xwayland.rs" ]
49+ mod xwayland;
4850#[ cfg( not( target_os = "macos" ) ) ]
4951pub ( crate ) use placement:: monitor_at;
5052use placement:: { monitor, position} ;
@@ -611,24 +613,6 @@ impl<T: 'static> Overlay<T> {
611613 None
612614 }
613615
614- /// The compositor has no layer-shell (GNOME): an overlay that takes no input shows on
615- /// XWayland when there is one.
616- #[ cfg( all( unix, not( target_os = "macos" ) , not( target_os = "ios" ) , not( target_os = "android" ) ) ) ]
617- fn xwayland ( & mut self ) -> Option < Live > {
618- if self . options . input . resolved ( self . interactive ) != OverlayInput :: None || self . options . keys == KeyPolicy :: OnDemand { return None ; }
619- let surface = crate :: x11:: xwayland:: XwaylandSurface :: new ( self . name , self . at , & self . options ) ?;
620- let scale = surface. scale ( ) ;
621- self . shared . native . lock ( ) . unwrap ( ) . 1 = crate :: OverlayCapabilities {
622- capture_exclusion : OverlaySupport :: Unsupported , global_pointer : OverlaySupport :: Unsupported , nonactivating_keys : OverlaySupport :: Unsupported ,
623- } ;
624- self . attach ( Backing :: Xwayland ( surface) , scale)
625- }
626-
627- #[ cfg( not( all( unix, not( target_os = "macos" ) , not( target_os = "ios" ) , not( target_os = "android" ) ) ) ) ]
628- fn xwayland ( & mut self ) -> Option < Live > {
629- None
630- }
631-
632616 fn window ( & mut self , event_loop : & ActiveEventLoop ) -> Option < Live > {
633617 let mut attrs = Window :: default_attributes ( )
634618 . with_title ( self . name )
0 commit comments