Simplify condition

This commit is contained in:
Ivan Molodetskikh
2025-04-12 09:44:49 +03:00
parent 5cd8040d1a
commit 9e5e0c85bb
+6 -3
View File
@@ -2872,11 +2872,14 @@ impl Niri {
} }
let mon = self.layout.monitor_for_output(output).unwrap(); let mon = self.layout.monitor_for_output(output).unwrap();
if !mon.render_above_top_layer() if mon.render_above_top_layer() {
&& (layer_popup_under(Layer::Top) return false;
}
if layer_popup_under(Layer::Top)
|| layer_toplevel_under(Layer::Top) || layer_toplevel_under(Layer::Top)
|| layer_popup_under(Layer::Bottom) || layer_popup_under(Layer::Bottom)
|| layer_popup_under(Layer::Background)) || layer_popup_under(Layer::Background)
{ {
return true; return true;
} }