WaylandWindow: Don't move windows to null output when the size is empty

Do not decide on the output when the window is empty, contains won't
report empty rects. We'll be sending leave events unnecessarily.
Make sure we don't pass unexisting outputs.

Signed-off-by: Victoria Fischer <victoria.fischer@mbition.io>
wilder/Plasma/6.3
Aleix Pol Gonzalez 2 years ago committed by Aleix Pol Gonzalez
parent 99a04955c1
commit 45feca5df4
  1. 9
      src/waylandwindow.cpp

@ -151,8 +151,13 @@ void WaylandWindow::updateClientOutputs()
if (isDeleted()) {
return;
}
surface()->setOutputs(waylandServer()->display()->outputsIntersecting(frameGeometry().toAlignedRect()),
waylandServer()->display()->largestIntersectingOutput(frameGeometry().toAlignedRect()));
const auto rect = frameGeometry().toAlignedRect();
if (rect.isEmpty()) {
return;
}
surface()->setOutputs(waylandServer()->display()->outputsIntersecting(rect),
waylandServer()->display()->largestIntersectingOutput(rect));
}
void WaylandWindow::updateIcon()

Loading…
Cancel
Save