awesomewm/modules/mpc/keybinds.lua

54 lines
805 B
Lua
Raw Normal View History

local mpc = req_rel(..., "util")
2021-08-01 07:24:26 -07:00
return gears.table.join(
awful.key( {}, "XF86AudioPrev",
function ()
mpc.mpc_command("prev")
2021-08-01 07:24:26 -07:00
end,
{
description = "Previous track",
group = "MPC"
2021-08-01 07:24:26 -07:00
}
),
awful.key( {}, "XF86AudioPlay",
function ()
mpc.mpc_command("toggle")
2021-08-01 07:24:26 -07:00
end,
{
description = "Play/Pause",
group = "MPC"
2021-08-01 07:24:26 -07:00
}
),
awful.key( {}, "XF86AudioNext",
function ()
mpc.mpc_command("next")
2021-08-01 07:24:26 -07:00
end,
{
description = "Next track",
group = "MPC"
2021-08-01 07:24:26 -07:00
}
),
awful.key( {"Mod4"}, "XF86AudioRaiseVolume",
function ()
mpc.mpc_command("vol +5")
2021-08-01 07:24:26 -07:00
end,
{
description = "Volume up",
group = "MPC"
2021-08-01 07:24:26 -07:00
}
),
awful.key( {"Mod4"}, "XF86AudioLowerVolume",
function ()
mpc.mpc_command("vol -5")
2021-08-01 07:24:26 -07:00
end,
{
description = "Volume down",
group = "MPC"
2021-08-01 07:24:26 -07:00
}
)
)