diff --git a/src/window.cpp b/src/window.cpp index d2cf753332..ff86301c74 100644 --- a/src/window.cpp +++ b/src/window.cpp @@ -636,12 +636,6 @@ bool Window::belongsToDesktop() const Layer Window::layerForDock() const { - // slight hack for the 'allow window to cover panel' Kicker setting - // don't move keepbelow docks below normal window, but only to the same - // layer, so that both may be raised to cover the other - if (keepBelow()) { - return NormalLayer; - } if (keepAbove()) { // slight hack for the autohiding panels return AboveLayer; } diff --git a/src/x11window.cpp b/src/x11window.cpp index 2e7fe7071d..8143b4ce4f 100644 --- a/src/x11window.cpp +++ b/src/x11window.cpp @@ -2898,11 +2898,6 @@ Xcb::Property X11Window::fetchShowOnScreenEdge() const void X11Window::readShowOnScreenEdge(Xcb::Property &property) { - // value comes in two parts, edge in the lower byte - // then the type in the upper byte - // 0 = autohide - // 1 = raise in front on activate - const uint32_t value = property.value(ElectricNone); ElectricBorder border = ElectricNone; switch (value & 0xFF) { @@ -2920,28 +2915,15 @@ void X11Window::readShowOnScreenEdge(Xcb::Property &property) break; } if (border != ElectricNone) { - disconnect(m_edgeRemoveConnection); disconnect(m_edgeGeometryTrackingConnection); - bool successfullyHidden = false; - if (((value >> 8) & 0xFF) == 1) { - setKeepBelow(true); - successfullyHidden = keepBelow(); // request could have failed due to user kwin rules + hideClient(); + const bool successfullyHidden = isHiddenInternal(); - m_edgeRemoveConnection = connect(this, &Window::keepBelowChanged, this, [this]() { - if (!keepBelow()) { - workspace()->screenEdges()->reserve(this, ElectricNone); - } - }); - } else { + m_edgeGeometryTrackingConnection = connect(this, &X11Window::frameGeometryChanged, this, [this, border]() { hideClient(); - successfullyHidden = isHiddenInternal(); - - m_edgeGeometryTrackingConnection = connect(this, &X11Window::frameGeometryChanged, this, [this, border]() { - hideClient(); - workspace()->screenEdges()->reserve(this, border); - }); - } + workspace()->screenEdges()->reserve(this, border); + }); if (successfullyHidden) { workspace()->screenEdges()->reserve(this, border); @@ -2970,10 +2952,7 @@ void X11Window::updateShowOnScreenEdge() void X11Window::showOnScreenEdge() { - disconnect(m_edgeRemoveConnection); - showClient(); - setKeepBelow(false); xcb_delete_property(kwinApp()->x11Connection(), window(), atoms->kde_screen_edge_show); } diff --git a/src/x11window.h b/src/x11window.h index 516d40a842..c602628796 100644 --- a/src/x11window.h +++ b/src/x11window.h @@ -523,7 +523,6 @@ private: QTimer *m_focusOutTimer; QTimer m_releaseTimer; - QMetaObject::Connection m_edgeRemoveConnection; QMetaObject::Connection m_edgeGeometryTrackingConnection; QMarginsF m_clientFrameExtents;