diff options
author | Gerd Hoffmann <kraxel@redhat.com> | 2019-01-18 13:08:33 +0100 |
---|---|---|
committer | Gerd Hoffmann <kraxel@redhat.com> | 2019-01-18 13:08:33 +0100 |
commit | 6dd9dfd266aae08880a9634c1ec015043258f92f (patch) | |
tree | 3958f1286a800cb3035edab7058037390d44fe66 /kbd.c | |
parent | d88041d909b2118ebc67b356b2848fb8bdfc8f2c (diff) | |
download | fbida-6dd9dfd266aae08880a9634c1ec015043258f92f.tar.gz |
libinput: handle console switches
Diffstat (limited to 'kbd.c')
-rw-r--r-- | kbd.c | 15 |
1 files changed, 14 insertions, 1 deletions
@@ -209,7 +209,8 @@ static int open_restricted(const char *path, int flags, void *user_data) } fprintf(stderr, "using %s\n", path); - ioctl(fd, EVIOCGRAB, 1); + if (devgrab) + ioctl(fd, EVIOCGRAB, 1); devcount++; return fd; } @@ -318,3 +319,15 @@ int kbd_read(char *buf, uint32_t len, return rc; } } + +void kbd_suspend(void) +{ + if (ctx) + libinput_suspend(ctx); +} + +void kbd_resume(void) +{ + if (ctx) + libinput_resume(ctx); +} |