x11: Simplify X11Output::geometry()

There is a separate type for placeholder x11 outputs, so X11Output can
return its geometry without performing any checks.
This commit is contained in:
Vlad Zahorodnii 2021-08-30 10:35:21 +03:00
parent 9dfccfc95c
commit 96830d2295

View file

@ -7,7 +7,7 @@
SPDX-License-Identifier: GPL-2.0-or-later
*/
#include "x11_output.h"
#include "screens.h"
#include "kwinglobals.h"
namespace KWin
{
@ -25,10 +25,7 @@ QString X11Output::name() const
QRect X11Output::geometry() const
{
if (m_geometry.isValid()) {
return m_geometry;
}
return QRect(QPoint(0, 0), Screens::self()->displaySize()); // xinerama, lacks RandR
return m_geometry;
}
void X11Output::setGeometry(QRect set)