Update Smithay, with Window that supports X11 surfaces

This commit is contained in:
Ian Douglas Scott 2024-02-21 13:24:56 -08:00 committed by Victoria Brekenfeld
parent 849882a7db
commit 3036448c19
24 changed files with 482 additions and 619 deletions

View file

@ -20,7 +20,7 @@ use tracing::{debug, trace};
use self::target::{KeyboardFocusTarget, WindowGroup};
use super::{layout::floating::FloatingLayout, CosmicSurface};
use super::layout::floating::FloatingLayout;
pub mod target;
@ -207,11 +207,11 @@ fn raise_with_children(floating_layer: &mut FloatingLayout, focused: &CosmicMapp
.space
.elements()
.filter(|elem| {
let parent = match elem.active_window() {
CosmicSurface::Wayland(w) => w.toplevel().parent(),
_ => None,
};
let parent = elem
.active_window()
.0
.toplevel()
.and_then(|toplevel| toplevel.parent());
parent == focused.active_window().wl_surface()
})
.cloned()