diff options
author | Vincent Vanlaer <vincent.vanlaer@skynet.be> | 2018-05-06 22:22:39 +0200 |
---|---|---|
committer | Vincent Vanlaer <vincent.vanlaer@skynet.be> | 2018-05-06 23:41:29 +0200 |
commit | 31861b3a7a2a4f3dc278278dadec60a70138c74e (patch) | |
tree | 203964572b0580a96d5e5f51904ff400e590f1cd | |
parent | c80bf1591e5cea26bd29e1b4b4680d4ef3693833 (diff) |
Add option to rootston to start xwayland lazy
-rw-r--r-- | include/rootston/config.h | 1 | ||||
-rw-r--r-- | rootston/config.c | 4 | ||||
-rw-r--r-- | rootston/desktop.c | 2 |
3 files changed, 6 insertions, 1 deletions
diff --git a/include/rootston/config.h b/include/rootston/config.h index 0a67ac1e..97a8baab 100644 --- a/include/rootston/config.h +++ b/include/rootston/config.h @@ -60,6 +60,7 @@ struct roots_cursor_config { struct roots_config { bool xwayland; + bool xwayland_lazy; struct wl_list outputs; struct wl_list devices; diff --git a/rootston/config.c b/rootston/config.c index 67bf83e9..bbdb7990 100644 --- a/rootston/config.c +++ b/rootston/config.c @@ -240,6 +240,9 @@ static int config_ini_handler(void *user, const char *section, const char *name, if (strcmp(name, "xwayland") == 0) { if (strcasecmp(value, "true") == 0) { config->xwayland = true; + } else if (strcasecmp(value, "lazy") == 0) { + config->xwayland = true; + config->xwayland_lazy = true; } else if (strcasecmp(value, "false") == 0) { config->xwayland = false; } else { @@ -389,6 +392,7 @@ struct roots_config *roots_config_create_from_args(int argc, char *argv[]) { } config->xwayland = true; + config->xwayland_lazy = false; wl_list_init(&config->outputs); wl_list_init(&config->devices); wl_list_init(&config->keyboards); diff --git a/rootston/desktop.c b/rootston/desktop.c index 06c188d8..7be1c64a 100644 --- a/rootston/desktop.c +++ b/rootston/desktop.c @@ -835,7 +835,7 @@ struct roots_desktop *desktop_create(struct roots_server *server, if (config->xwayland) { desktop->xwayland = wlr_xwayland_create(server->wl_display, - desktop->compositor, false); + desktop->compositor, config->xwayland_lazy); wl_signal_add(&desktop->xwayland->events.new_surface, &desktop->xwayland_surface); desktop->xwayland_surface.notify = handle_xwayland_surface; |