richardgv / skippy-xd

A full-screen Exposé-style standalone task switcher for X11.
GNU General Public License v2.0
340 stars 76 forks source link

'switchDesktopOnActivate' not works when client is iconified in awesome wm #46

Open actionless opened 10 years ago

actionless commented 10 years ago

Skippy works well when window is placed on other tag (it swiches to that tag when selecting preview).

But when window is iconified it only sends 'urgent' event to it but client still stays iconified.

richardgv commented 10 years ago

Sorry for the late reply, actionless.

It's indeed not our fault. Check ./lib/awful/ewmh.lua.in in awesome source code:

-- Activate a window
function ewmh.activate(c)
    if c:isvisible() then
        client.focus = c
        c:raise()
    elseif not awesome.startup then
        c.urgent = true
    end
end

So Awesome intentionally ignores EWMH focus events sent to invisible windows.

Probably there are other ways to de-iconify the window (ICCCM WM_CHANGE_STATE or simply XMapWindow()?), but EWMH _NET_WM_ACTIVE_WINDOW seemingly is the method most panels use.

actionless commented 10 years ago

thanks for pointing that out! i changed that routine to leave only the first case and it's working as expected now.

but i am still confused on why did awesome developers did it in that way (mb u hv any ideas?)

richardgv commented 10 years ago

I found a piece of related discussion here: https://awesome.naquadah.org/bugs/index.php?do=details&task_id=848

actionless commented 10 years ago

hm, after reading that it became even more confusing

i will try to run other panels inside awesome and will take a look if some of them behaves in a different way than skippy for restoring minimized client and if will find out smth interesting will post a ticket

actionless commented 10 years ago

so i tried few panels and yep, they're behave the same in this situation

how do u think, can it be useful to have an option to workaround that behavior? (i suspect it will be the same not only in awesome but in few other tiling WMs)

smth like useActivateWorkaround = true