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

cinnamon-maximus@fmete: Fix broken window ID getter #430

Closed
wants to merge 1 commit into from

Conversation

BlaiseRideout
Copy link

get_xwindow no longer exists so guessWindowXID always fails and falls back to using the window title, which always selects the bottom-most window of a given title where multiple windows exist with the same title.

Replacing it with get_description gets the correct ID and yields the correct behavior of decorating and undecorating the currently focused window

I also added the exception message to the log message to make debugging in the future easier should the API change again

Also added a comment for a potential workaround that would be agnostic to the cinnamon extension API changing which would utilize an external call to xprop to get the active window ID which might be preferred considering this extension already depends on an external call to xprop anyway. Let me know if you'd rather I implement that version

Using Cinnamon 5.4.12 on Mint 21

Fixes #428

@mtwebster
Copy link
Member

I've restored meta_window_get_xwindow (I would have sooner but didn't check for its use in spices, sorry).

linuxmint/muffin@e44d231
(Will be in the next point release).

Maybe there could be a try/catch here to use it if it's there, and the description-based check if not.

@claudiux
Copy link
Member

@BlaiseRideout Is this PR still relevant? There are conflicts in this branch that need to be resolved, so I suggest you create a new one if that proves useful.

@claudiux claudiux closed this Jul 23, 2023
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.

cinnamon-maximus@fmete Could not find XID for window with title
3 participants