diff --git a/autotests/integration/dbus_interface_test.cpp b/autotests/integration/dbus_interface_test.cpp index e324faefd2..a64b5269fd 100644 --- a/autotests/integration/dbus_interface_test.cpp +++ b/autotests/integration/dbus_interface_test.cpp @@ -137,7 +137,7 @@ void TestDbusInterface::testGetWindowInfoXdgShellClient() QCOMPARE(windowData.value(QStringLiteral("skipSwitcher")).toBool(), false); QCOMPARE(windowData.value(QStringLiteral("maximizeHorizontal")).toBool(), false); QCOMPARE(windowData.value(QStringLiteral("maximizeVertical")).toBool(), false); - QCOMPARE(windowData.value(QStringLiteral("noBorder")).toBool(), true); + QCOMPARE(windowData.value(QStringLiteral("noBorder")).toBool(), false); QCOMPARE(windowData.value(QStringLiteral("clientMachine")).toString(), QString()); QCOMPARE(windowData.value(QStringLiteral("localhost")).toBool(), true); QCOMPARE(windowData.value(QStringLiteral("role")).toString(), QString()); diff --git a/src/useractions.cpp b/src/useractions.cpp index b97c12898d..f056de21d1 100644 --- a/src/useractions.cpp +++ b/src/useractions.cpp @@ -1217,7 +1217,9 @@ void Workspace::performWindowOperation(AbstractClient* c, Options::WindowOperati c->setFullScreen(!c->isFullScreen(), true); break; case Options::NoBorderOp: - c->setNoBorder(!c->noBorder()); + if (c->userCanSetNoBorder()) { + c->setNoBorder(!c->noBorder()); + } break; case Options::KeepAboveOp: { StackingUpdatesBlocker blocker(this); diff --git a/src/xdgshellclient.cpp b/src/xdgshellclient.cpp index 4e778e6bd2..906078d874 100644 --- a/src/xdgshellclient.cpp +++ b/src/xdgshellclient.cpp @@ -741,14 +741,11 @@ bool XdgToplevelClient::userCanSetNoBorder() const bool XdgToplevelClient::noBorder() const { - return m_userNoBorder || preferredDecorationMode() != DecorationMode::Server; + return m_userNoBorder; } void XdgToplevelClient::setNoBorder(bool set) { - if (!userCanSetNoBorder()) { - return; - } set = rules()->checkNoBorder(set); if (m_userNoBorder == set) { return;