blob: 098eb0299725fad93b5b781d196e1785062d678c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
diff --git a/slock.c b/slock.c
index 5ae738c..bd54be2 100644
--- a/slock.c
+++ b/slock.c
@@ -18,6 +18,7 @@
#include <X11/Xlib.h>
#include <X11/Xutil.h>
#include <X11/XKBlib.h>
+#include <X11/XF86keysym.h>
#include "arg.h"
#include "util.h"
@@ -157,6 +158,18 @@ readpw(Display *dpy, struct xrandr *rr, struct lock **locks, int nscreens,
IsPrivateKeypadKey(ksym))
continue;
switch (ksym) {
+ case XF86XK_AudioPlay:
+ case XF86XK_AudioStop:
+ case XF86XK_AudioPrev:
+ case XF86XK_AudioNext:
+ case XF86XK_AudioRaiseVolume:
+ case XF86XK_AudioLowerVolume:
+ case XF86XK_AudioMute:
+ case XF86XK_AudioMicMute:
+ case XF86XK_MonBrightnessDown:
+ case XF86XK_MonBrightnessUp:
+ XSendEvent(dpy, DefaultRootWindow(dpy), True, KeyPressMask, &ev);
+ break;
case XK_Return:
passwd[len] = '\0';
errno = 0;
|