summaryrefslogtreecommitdiff
path: root/tools/interactive-wayland.c
diff options
context:
space:
mode:
authorRan Benita <ran@unusedvar.com>2020-06-28 09:50:47 +0300
committerRan Benita <ran@unusedvar.com>2020-06-28 09:50:47 +0300
commit878cc7a57495fa0bc1fbcb7cc666ad75cb6cdb65 (patch)
treed997835a8125a79d5d8b74267e98ff0241383f62 /tools/interactive-wayland.c
parent8b8a464576789b13e2d48d4ede662acac3141263 (diff)
downloadxorg-lib-libxkbcommon-878cc7a57495fa0bc1fbcb7cc666ad75cb6cdb65.tar.gz
tools: don't depend on src/utils.h
The idea is to make the tools/demos as standalone as possible so that they may serve as examples as well. Signed-off-by: Ran Benita <ran@unusedvar.com>
Diffstat (limited to 'tools/interactive-wayland.c')
-rw-r--r--tools/interactive-wayland.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/tools/interactive-wayland.c b/tools/interactive-wayland.c
index 0ffccd0..8cc41de 100644
--- a/tools/interactive-wayland.c
+++ b/tools/interactive-wayland.c
@@ -28,9 +28,12 @@
#include <errno.h>
#include <fcntl.h>
#include <locale.h>
+#include <stdbool.h>
#include <stdint.h>
-#include <unistd.h>
+#include <stdlib.h>
+#include <string.h>
#include <sys/mman.h>
+#include <unistd.h>
#include "xkbcommon/xkbcommon.h"
#include "tools-common.h"
@@ -39,6 +42,8 @@
#include "xdg-shell-client-protocol.h"
#include <wayland-util.h>
+#define MAX(a, b) ((a) > (b) ? (a) : (b))
+
struct interactive_dpy {
struct wl_display *dpy;
struct wl_compositor *compositor;