CZ-NIC/run-or-raise

Shortcut to Nautilus does not cycle through windows

Closed this issue · 3 comments

Ubuntu 22.04, Wayland

With nautilus (and perhaps other applications, there is erroneous behavior when multiple windows are open:

f,nautilus,nautilus, # same for: nautilus,org.gnome.Nautilus,

does not cycle through the open windows. What is worse, the same window is always focussed, even if previously, another nautilus window was selected.

Steps to reproduce:
Empty desktop

  1. Define shortcut key as above
  2. Hit the shortcut to open a nautilus window. Hit Ctrl+N to open a second nautilus window
  3. Open a browser
  4. Press shortcut key: the second nautilus window is focused (correctly, thus far)
  5. Press shortcut key again: nothing changes (expected: the other nautilus window is now focused)
  6. Press Alt+key-above-tab to bring first nautilus window in focus
  7. Switch to browser
  8. Press shortcut key: the second nautilus window is focused (expected: the first window should be focused)

This erroneous behavior is specific to nautilus - it works correctly with e.g. multiple windows of gedit or firefox.

e3rd commented

Thanks for having written the steps for reproduce! Are you sure you've used the same wm_class string as seen in the lg? For me, the following (mind the big letter 'o') works perfectly.

<Super>m,nautilus,Org.gnome.Nautilus,
e3rd commented

I wonder that "any syntax" would work perfectly, I thought wm_class is case sensitive. Either Org.gnome.Nautilus or org.gnome.Nautilus should work, not both.

(Shortcut <Super>m,nautilus,, launches command nautilus every time and the program is so clever that it checks whether it is already running and if so, gots raised. It might be slightly slower to cycle some programs that way.)

If you need anything, I'm here :)