Repository navigation
fix: use hasFullscreen() in workspace swipe gesture for scrolling layout compatibility - #14736
AuthenticSm1les wants to merge 1 commit into
Conversation
β¦out compatibility
|
Hello and thank you for making a PR to Hyprland! Please check the PR Guidelines and make sure your PR follows them. If your code can be tested, please always add tests. See more here. beep boop, I'm just a bot. A real human will review your PR soon. |
|
Note: This PR was generated by an AI assistant and should be used as a reference/template for producing a proper fix. It has not been tested end-to-end and should not be merged as-is. The analysis and root cause identification are accurate, but the implementation should be reviewed and validated by a human maintainer before any merge. |
|
I have same issue with this |
|
This should be fixed with #14705. I've tried to unify all FS checks to also handle layout handled fullscreens (i.e. scrolling) so that should take care of your problem. Please help test when it's done. |
Description
When using scrolling layout (
tiledLayout: scrolling) with a TOP-layer bar (e.g. Waybar configured with"layer": "top"), the bar becomes visible on workspace switch via touchpad swipe gesture even when the target workspace has a fullscreen window.Root Cause
The workspace swipe gesture code in
UnifiedWorkspaceSwipeGesture.cppusesm_hasFullscreenWindowdirectly to determine layer-surface alpha. In scrolling layout, the layout algorithm handles fullscreen requests (LAYOUT_HANDLED_FULLSCREEN), causingsetWindowFullscreenState()inCompositor.cppto resetm_hasFullscreenWindow = falseandm_fullscreenMode = FSMODE_NONE.Since the swipe gesture checks
m_hasFullscreenWindow(which is false) instead ofhasFullscreen()(which also checkslayoutFullscreenCoversMonitor()), the bar alpha is always set to 1.0 (fully visible) even when the target workspace has a fullscreen window that covers the entire monitor.Changes
Two lines in
src/managers/input/UnifiedWorkspaceSwipeGesture.cpp:begin()β ReplacePWORKSPACE->m_hasFullscreenWindowwithPWORKSPACE->hasFullscreen()so that layout-handled fullscreen is correctly detected when starting a swipe.end()β ReplacepSwitchedTo->m_hasFullscreenWindow && pSwitchedTo->m_fullscreenMode == FSMODE_FULLSCREENwithpSwitchedTo->hasFullscreen() && pSwitchedTo->m_fullscreenMode != FSMODE_MAXIMIZEDto match the semantics ofsetFullscreenFadeAnimation()inDesktopAnimationManager.cpp(which also usesws->m_fullscreenMode != FSMODE_MAXIMIZED).AI-Generated Note
This PR was generated by an AI assistant and should be used as a reference/template for producing a proper fix. The analysis and root cause identification are accurate, but the implementation has not been tested end-to-end and should not be merged as-is. Please review and validate before any merge.
Related
PR #14425 introduced
hasFullscreen()but only updatedMonitor.cppcall sites. The swipe gesture code was missed.