aboutsummaryrefslogtreecommitdiffstats
path: root/sway/commands/xwayland.c
diff options
context:
space:
mode:
authorLibravatar emersion <contact@emersion.fr>2018-11-17 12:29:59 +0100
committerLibravatar emersion <contact@emersion.fr>2018-11-19 17:38:37 +0100
commit311c7db7e300bc9e749a582a56805150180138e0 (patch)
treea695f7af6143e47c8b7bb8afe32e2e8f59c39958 /sway/commands/xwayland.c
parentMerge pull request #3152 from camoz/master (diff)
downloadsway-311c7db7e300bc9e749a582a56805150180138e0.tar.gz
sway-311c7db7e300bc9e749a582a56805150180138e0.tar.zst
sway-311c7db7e300bc9e749a582a56805150180138e0.zip
Add xwayland command
Diffstat (limited to 'sway/commands/xwayland.c')
-rw-r--r--sway/commands/xwayland.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/sway/commands/xwayland.c b/sway/commands/xwayland.c
new file mode 100644
index 00000000..03a0121b
--- /dev/null
+++ b/sway/commands/xwayland.c
@@ -0,0 +1,21 @@
1#include "sway/config.h"
2#include "log.h"
3#include "sway/commands.h"
4#include "sway/server.h"
5#include "util.h"
6
7struct cmd_results *cmd_xwayland(int argc, char **argv) {
8 struct cmd_results *error = NULL;
9 if ((error = checkarg(argc, "xwayland", EXPECTED_EQUAL_TO, 1))) {
10 return error;
11 }
12
13#ifdef HAVE_XWAYLAND
14 config->xwayland = parse_boolean(argv[0], config->xwayland);
15#else
16 wlr_log(WLR_INFO, "Ignoring `xwayland` command, "
17 "sway hasn't been built with Xwayland support");
18#endif
19
20 return cmd_results_new(CMD_SUCCESS, NULL, NULL);
21}