diff --git a/src/activity.cpp b/src/activity.cpp index 93f3571..b7e3a13 100644 --- a/src/activity.cpp +++ b/src/activity.cpp @@ -53,7 +53,7 @@ bool Activity::launchPad() const { return m_launchPad; } - +#include void Activity::onActiveWindowChanged() { KWindowInfo info(KWindowSystem::activeWindow(), @@ -66,9 +66,9 @@ void Activity::onActiveWindowChanged() bool existsWindowMaximized = false; for (WId wid : KWindowSystem::windows()) { - KWindowInfo i(wid, NET::WMState); + KWindowInfo i(wid, NET::WMState, NET::WM2WindowClass); - if (i.isMinimized()) + if (i.isMinimized() || i.hasState(NET::SkipTaskbar)) continue; if (i.hasState(NET::MaxVert) || i.hasState(NET::MaxHoriz)) { diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 44475f2..9330484 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -368,13 +368,14 @@ void MainWindow::onVisibilityChanged() if (m_activity->launchPad()) return; - else - m_hideBlocked = false; if (m_settings->visibility() == DockSettings::IntellHide) { clearViewStruts(); setGeometry(windowRect()); + if (!m_fakeWindow && !m_activity->existsWindowMaximized()) + m_hideBlocked = false; + if (m_activity->existsWindowMaximized() && !m_hideBlocked) { setVisible(false); } else { @@ -389,7 +390,7 @@ void MainWindow::onVisibilityChanged() if (m_settings->visibility() == DockSettings::AlwaysHide) { clearViewStruts(); setGeometry(windowRect()); - setVisible(false); + setVisible(m_hideBlocked); // Create if (!m_fakeWindow) diff --git a/src/xwindowinterface.cpp b/src/xwindowinterface.cpp index ea5327a..1c673fc 100644 --- a/src/xwindowinterface.cpp +++ b/src/xwindowinterface.cpp @@ -149,7 +149,7 @@ void XWindowInterface::setViewStruts(QWindow *view, DockSettings::Direction dire const auto screen = view->screen(); - const QRect currentScreen {screen->geometry()}; + // const QRect currentScreen {screen->geometry()}; const QRect wholeScreen { {0, 0}, screen->virtualSize() }; const int edgeMargins = compositing ? DockSettings::self()->edgeMargins() : 0;