瀏覽代碼

~/.config/dwm: Support muting/unmuting audio

Lucas Stadler 9 年之前
父節點
當前提交
f72cc3c6b5
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      .config/dwm/config.h

+ 2 - 0
.config/dwm/config.h

@ -66,6 +66,7 @@ static const char *termcmd[]  = { "/usr/bin/sakura", NULL };
66 66
67 67
static const char *volumedowncmd[] = { "amixer", "set", "Master", "5%-", NULL };
68 68
static const char *volumeupcmd[] = { "amixer", "set", "Master", "5%+", NULL };
69
static const char *volumetogglecmd[] = { "amixer", "set", "Master", "toggle", NULL };
69 70
70 71
static const char *screenlockcmd[] = { "slock", NULL };
71 72
@ -107,6 +108,7 @@ static Key keys[] = {
107 108
108 109
	{ 0,                            XF86XK_AudioLowerVolume, spawn, { .v = volumedowncmd } },
109 110
	{ 0,                            XF86XK_AudioRaiseVolume, spawn, { .v = volumeupcmd } },
111
	{ 0,                            XF86XK_AudioMute       , spawn, { .v = volumetogglecmd } },
110 112
111 113
	{ MODKEY|ShiftMask,             XK_l,      spawn,          { .v = screenlockcmd } },
112 114
};