Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

only sink window if actually fullscreened #866

Merged
merged 1 commit into from
Jan 21, 2024

Conversation

geekosaur
Copy link
Contributor

@geekosaur geekosaur commented Jan 18, 2024

Description

EwmhFullscreen unconditionally sinks windows in response to a _NET_WM_STATE root window message removing _NET_WM_STATE_FULLSCREEN. Unfortunately, at least some versions of either the Gtk or GNOME libraries send this on startup while restoring a window's last known state, which means a manageHook doFloat will be undone.

This change ignores the remove if the window is not fullscreen.

A followup issue, #865, has been added for the follow-on problem that the floating state of a window is not restored on removal of the fullscreen state.

Closes: #820

Checklist

  • I've read CONTRIBUTING.md

  • I've considered how to best test these changes (property, unit,
    manually, ...) and concluded: a user is already using this change successfully

  • I updated the CHANGES.md file (unnecessary)

@@ -548,7 +548,7 @@ fullscreenEventHook'
when (action == add || (action == toggle && not isFull)) $ do
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm, do we perhaps want to make the same change here to prevent windows from being fullscreened multiple times if a rogue app makes multiple add requests?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I left that one alone because it seems to be idempotent.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But we have no idea what fullscreenHook does so it's only idempotent with the default one.

`EwmhFullscreen` unconditionally sinks windows in response to a
`_NET_WM_STATE` root window message removing `_NET_WM_STATE_FULLSCREEN`.
Unfortunately, at least some versions of either the Gtk or GNOME
libraries send this on startup while restoring a window's last
known state, which means a `manageHook` `doFloat` will be undone.

This change ignores the remove if the window is not fullscreen.

A followup issue, xmonad#865, has been added for the follow-on problem
that the floating state of a window is not restored on removal of
the fullscreen state.

Fixes: xmonad#820
@geekosaur geekosaur merged commit 318ee92 into xmonad:master Jan 21, 2024
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Dialog window (zenity) not floated when ewmhFullscreen present
3 participants