Merge pull request #474 from blueyed/ewmh-activate-only-focus-visible

ewmh.activate: only focus visible clients
This commit is contained in:
Daniel Hahler 2015-09-25 10:15:25 +02:00
commit bd39a70b62
1 changed files with 3 additions and 1 deletions

View File

@ -160,7 +160,9 @@ end
-- @tparam[opt] table hints A table with additional hints: -- @tparam[opt] table hints A table with additional hints:
-- @tparam[opt=false] boolean hints.raise should the client be raised? -- @tparam[opt=false] boolean hints.raise should the client be raised?
function ewmh.activate(c, context, hints) function ewmh.activate(c, context, hints)
if c:isvisible() then
client.focus = c client.focus = c
end
if hints and hints.raise then if hints and hints.raise then
if awesome.startup or c:isvisible() then if awesome.startup or c:isvisible() then
c:raise() c:raise()