diff options
| author | jmanc3 <jman12316@live.com> | 2025-07-27 08:11:07 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-07-27 15:11:07 +0200 |
| commit | 211199e864a4d8d7c1c6e0ebf38f58f0c7debaa7 (patch) | |
| tree | 06575b2d06d31ab1137632b4d8e58777a164e111 /src/desktop/Window.cpp | |
| parent | e1fff05d0db9c266679ec7ea1b5734c73d6b0a57 (diff) | |
fix: include decorations in visibleOnMonitor calculation (#11232)
Fixes: https://github.com/hyprwm/Hyprland/discussions/11203
The window turned invisible when just outside the monitor bounds, even though it should have stayed visible given its decorations.
The fix was to include the decorations when determining if a window is on a monitor.
Diffstat (limited to 'src/desktop/Window.cpp')
| -rw-r--r-- | src/desktop/Window.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/desktop/Window.cpp b/src/desktop/Window.cpp index 6563727a..a42a27fe 100644 --- a/src/desktop/Window.cpp +++ b/src/desktop/Window.cpp @@ -1261,6 +1261,9 @@ void CWindow::setSuspended(bool suspend) { bool CWindow::visibleOnMonitor(PHLMONITOR pMonitor) { CBox wbox = {m_realPosition->value(), m_realSize->value()}; + if (m_isFloating) + wbox = getFullWindowBoundingBox(); + return !wbox.intersection({pMonitor->m_position, pMonitor->m_size}).empty(); } |
