Prevent pointer focus to windows when locked

This commit is contained in:
Ottatop 2024-05-15 17:13:52 -05:00
parent 1faab2a68f
commit 333c805bdd

View file

@ -190,11 +190,15 @@ impl Pinnacle {
.output_geometry(output)
.expect("called output_geometry on unmapped output");
if let Some(lock_surface) = output.with_state(|state| state.lock_surface.clone()) {
return Some((
PointerFocusTarget::WlSurface(lock_surface.wl_surface().clone()),
output_geo.loc,
));
if !self.lock_state.is_unlocked() {
return output
.with_state(|state| state.lock_surface.clone())
.map(|lock_surface| {
(
PointerFocusTarget::WlSurface(lock_surface.wl_surface().clone()),
output_geo.loc,
)
});
}
let mut fullscreen_and_up_split_at = 0;