render: Include OutputId in namespaces

This commit is contained in:
Victoria Brekenfeld 2026-06-10 18:05:57 +02:00 committed by Victoria Brekenfeld
parent 361a2282c7
commit 1f0456a5af

View file

@ -27,7 +27,7 @@ use crate::{
},
config::ScreenFilter,
shell::{
CosmicMappedRenderElement, OverviewMode, SeatExt, Trigger, WorkspaceDelta,
CosmicMappedRenderElement, OutputId, OverviewMode, SeatExt, Trigger, WorkspaceDelta,
WorkspaceRenderElement,
element::CosmicMappedKey,
focus::{FocusTarget, Stage, render_input_order, target::WindowGroup},
@ -844,6 +844,12 @@ where
})
.unwrap_or([0; 4]);
let namespace = output
.user_data()
.get::<OutputId>()
.map(|id| id.namespace_for_workspace(workspace_idx))
.unwrap_or(workspace_idx);
push_render_elements_from_surface_tree(
renderer,
popup.wl_surface(),
@ -861,7 +867,7 @@ where
FRAME_TIME_FILTER,
&mut |elem| {
elements.extend(
crop_to_output(NamespacedElement::new(elem, workspace_idx).into())
crop_to_output(NamespacedElement::new(elem, namespace).into())
.map(Into::into),
)
},
@ -887,6 +893,12 @@ where
})
.unwrap_or([0; 4]);
let namespace = output
.user_data()
.get::<OutputId>()
.map(|id| id.namespace_for_workspace(workspace_idx))
.unwrap_or(workspace_idx);
push_render_elements_from_surface_tree(
renderer,
layer.wl_surface(),
@ -904,7 +916,7 @@ where
FRAME_TIME_FILTER,
&mut |elem| {
elements.extend(
crop_to_output(NamespacedElement::new(elem, workspace_idx).into())
crop_to_output(NamespacedElement::new(elem, namespace).into())
.map(Into::into),
)
},