aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGabriel Ford <[email protected]>2024-05-03 01:00:58 +0000
committerGitHub <[email protected]>2024-05-03 02:00:58 +0100
commit0623cfabc905ce50b192814be5cd33e05d8873e0 (patch)
treea90b1c24bdeff6dfbef3c61baf2fb7c2429c8387
parent27552976705e416ce481ca74d377578bcbc134e0 (diff)
downloadHyprland-0623cfabc905ce50b192814be5cd33e05d8873e0.tar.gz
Hyprland-0623cfabc905ce50b192814be5cd33e05d8873e0.zip
windowrules: Fix Floating Grouped Windows Crash and Bug. (#5826)
* Don't unhide grouped items. * Remove head check as that wasn't always correct. * Replace lock with expired() * Remove set hidden from max size.
-rw-r--r--src/desktop/Window.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/desktop/Window.cpp b/src/desktop/Window.cpp
index 04797f8b..ee942ff5 100644
--- a/src/desktop/Window.cpp
+++ b/src/desktop/Window.cpp
@@ -702,7 +702,6 @@ void CWindow::applyDynamicRule(const SWindowRule& r) {
m_vRealSize = Vector2D(std::min((double)m_sAdditionalConfigData.maxSize.toUnderlying().x, m_vRealSize.goal().x),
std::min((double)m_sAdditionalConfigData.maxSize.toUnderlying().y, m_vRealSize.goal().y));
g_pXWaylandManager->setWindowSize(m_pSelf.lock(), m_vRealSize.goal());
- setHidden(false);
} catch (std::exception& e) { Debug::log(ERR, "maxsize rule \"{}\" failed with: {}", r.szRule, e.what()); }
} else if (r.szRule.starts_with("minsize")) {
try {
@@ -718,7 +717,8 @@ void CWindow::applyDynamicRule(const SWindowRule& r) {
m_vRealSize = Vector2D(std::max((double)m_sAdditionalConfigData.minSize.toUnderlying().x, m_vRealSize.goal().x),
std::max((double)m_sAdditionalConfigData.minSize.toUnderlying().y, m_vRealSize.goal().y));
g_pXWaylandManager->setWindowSize(m_pSelf.lock(), m_vRealSize.goal());
- setHidden(false);
+ if (m_sGroupData.pNextWindow.expired())
+ setHidden(false);
} catch (std::exception& e) { Debug::log(ERR, "minsize rule \"{}\" failed with: {}", r.szRule, e.what()); }
}
}