Skip to content

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

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

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

cben
Copy link

@cben cben commented Apr 26, 2016

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
Copy link
Author

cben commented Apr 26, 2016

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