rules: apply keyboard layer 3 to window classes starting with steam_app_
This commit is contained in:
parent
821d35c8df
commit
61fd6aef87
1 changed files with 7 additions and 0 deletions
|
|
@ -37,6 +37,10 @@ local screen_chat = math.min(localconf.screen.chat or screen.count(), screen.cou
|
||||||
local screen_mail = math.min(localconf.screen.mail or screen.count(), screen.count())
|
local screen_mail = math.min(localconf.screen.mail or screen.count(), screen.count())
|
||||||
print("Screens: main: " .. screen_main .. ", chat: " .. screen_chat .. ", mail: " .. screen_mail)
|
print("Screens: main: " .. screen_main .. ", chat: " .. screen_chat .. ", mail: " .. screen_mail)
|
||||||
|
|
||||||
|
function startswith(str, start)
|
||||||
|
return str:sub(1, #start) == start
|
||||||
|
end
|
||||||
|
|
||||||
awful.rules.rules = {
|
awful.rules.rules = {
|
||||||
-- All clients will match this rule.
|
-- All clients will match this rule.
|
||||||
{
|
{
|
||||||
|
|
@ -55,6 +59,9 @@ awful.rules.rules = {
|
||||||
},
|
},
|
||||||
-- log name and class of new windows for debugging purposes
|
-- log name and class of new windows for debugging purposes
|
||||||
callback = function(c)
|
callback = function(c)
|
||||||
|
if startswith(c["class"], "steam_app_") then
|
||||||
|
keyboard_layer(3)(c)
|
||||||
|
end
|
||||||
log("-----------\nnew client\n")
|
log("-----------\nnew client\n")
|
||||||
if c["name"] ~= nil then
|
if c["name"] ~= nil then
|
||||||
log("name: " .. c["name"])
|
log("name: " .. c["name"])
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue