wayland: Use true logical geometry in Display::outputsIntersecting()

Display::outputsIntersecting() computes the logical geometry using the
oriented mode size and the scale factor, but OutputInterface's scale
factor is ceil()ed up, so the resulting logical geometry can be incorrect.

BUG: 459733
This commit is contained in:
Vlad Zahorodnii 2022-09-27 13:57:10 +03:00
parent 388350f8bf
commit f343f3fb80

View file

@ -166,8 +166,7 @@ QVector<OutputInterface *> Display::outputsIntersecting(const QRect &rect) const
{
QVector<OutputInterface *> outputs;
for (auto *output : qAsConst(d->outputs)) {
const QRect outputGeometry(output->globalPosition(), output->pixelSize() / output->scale());
if (rect.intersects(outputGeometry)) {
if (output->handle()->geometry().intersects(rect)) {
outputs << output;
}
}