diff options
author | Tony Crisci <[email protected]> | 2018-01-20 14:10:11 -0500 |
---|---|---|
committer | Tony Crisci <[email protected]> | 2018-01-20 14:10:11 -0500 |
commit | c353e01c85049cfbc09510657e453b6aa5fd9c2d (patch) | |
tree | c6ef14cfc08861ff8c62675ca1fbbbb00e9197cf /sway/desktop/xwayland.c | |
parent | cc3c713889e529c74888d9cd89af7039bfbae20c (diff) |
add kill command
Diffstat (limited to 'sway/desktop/xwayland.c')
-rw-r--r-- | sway/desktop/xwayland.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sway/desktop/xwayland.c b/sway/desktop/xwayland.c index a4d9687d..7603d3ca 100644 --- a/sway/desktop/xwayland.c +++ b/sway/desktop/xwayland.c @@ -80,6 +80,13 @@ static void set_activated(struct sway_view *view, bool activated) { wlr_xwayland_surface_activate(surface, activated); } +static void close(struct sway_view *view) { + if (!assert_xwayland(view)) { + return; + } + wlr_xwayland_surface_close(view->wlr_xwayland_surface); +} + static void handle_commit(struct wl_listener *listener, void *data) { struct sway_xwayland_surface *sway_surface = wl_container_of(listener, sway_surface, commit); @@ -192,6 +199,7 @@ void handle_xwayland_surface(struct wl_listener *listener, void *data) { sway_view->iface.set_size = set_size; sway_view->iface.set_position = set_position; sway_view->iface.set_activated = set_activated; + sway_view->iface.close = close; sway_view->wlr_xwayland_surface = xsurface; sway_view->sway_xwayland_surface = sway_surface; sway_view->surface = xsurface->surface; |