Skip to content

Use wmctrl (if installed) to raise and focus window.#1

Open
cben wants to merge 3 commits into
djeikyb:masterfrom
cben:raise-and-focus
Open

Use wmctrl (if installed) to raise and focus window.#1
cben wants to merge 3 commits into
djeikyb:masterfrom
cben:raise-and-focus

Conversation

@cben

@cben cben commented Apr 26, 2016

Copy link
Copy Markdown

The code already tells skype to 'FOCUS' but that doesn't work, at least for me.
(I'm on Fedora 23 with Cinnamon desktop.)
wmctrl works perfectly, so added code to run it and text to README to install it.

I also tried telling skype to close then restore the window — this did raise it, but kept it below the currently focused one. And it didn't seem to focus it all all.
Adding this as fallback when you don't have wmctrl installed.

@cben

cben commented Apr 26, 2016

Copy link
Copy Markdown
Author

Correction: if window didn't exist, wmctrl doesn't raise. On second run it does.
Might be a race condition, let's see... Yep, running wmctrl -l there shows sometimes the window doesn't exist yet. Let me try adding some polling...

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.

1 participant