From 0c6b418a5664470a21a01fccf3a29fee0d6885f5 Mon Sep 17 00:00:00 2001 From: Victoria Brekenfeld Date: Wed, 11 Oct 2023 19:16:51 +0200 Subject: [PATCH] move: Render translucent on non-active output --- src/shell/grabs/moving.rs | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/shell/grabs/moving.rs b/src/shell/grabs/moving.rs index 6af828c91..eda33d313 100644 --- a/src/shell/grabs/moving.rs +++ b/src/shell/grabs/moving.rs @@ -77,6 +77,11 @@ impl MoveGrabState { } else { 1.0 }; + let alpha = if &seat.active_output() == output { + 1.0 + } else { + 0.4 + }; let cursor_at = seat.get_pointer().unwrap().current_location(); @@ -115,7 +120,7 @@ impl MoveGrabState { .as_local(), self.indicator_thickness, output_scale.x, - 1.0, + alpha, )) .into(), ) @@ -130,7 +135,7 @@ impl MoveGrabState { (render_location - self.window.geometry().loc) .to_physical_precise_round(output_scale), output_scale, - 1.0, + alpha, ); self.stacking_indicator