diff options
Diffstat (limited to 'sway/desktop/xwayland.c')
-rw-r--r-- | sway/desktop/xwayland.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sway/desktop/xwayland.c b/sway/desktop/xwayland.c index 6e63c505..4bb35f60 100644 --- a/sway/desktop/xwayland.c +++ b/sway/desktop/xwayland.c | |||
@@ -417,6 +417,11 @@ static void handle_set_window_type(struct wl_listener *listener, void *data) { | |||
417 | view_execute_criteria(view); | 417 | view_execute_criteria(view); |
418 | } | 418 | } |
419 | 419 | ||
420 | struct sway_view *view_from_wlr_xwayland_surface( | ||
421 | struct wlr_xwayland_surface *xsurface) { | ||
422 | return xsurface->data; | ||
423 | } | ||
424 | |||
420 | void handle_xwayland_surface(struct wl_listener *listener, void *data) { | 425 | void handle_xwayland_surface(struct wl_listener *listener, void *data) { |
421 | struct sway_server *server = wl_container_of(listener, server, | 426 | struct sway_server *server = wl_container_of(listener, server, |
422 | xwayland_surface); | 427 | xwayland_surface); |
@@ -470,6 +475,8 @@ void handle_xwayland_surface(struct wl_listener *listener, void *data) { | |||
470 | 475 | ||
471 | wl_signal_add(&xsurface->events.map, &xwayland_view->map); | 476 | wl_signal_add(&xsurface->events.map, &xwayland_view->map); |
472 | xwayland_view->map.notify = handle_map; | 477 | xwayland_view->map.notify = handle_map; |
478 | |||
479 | xsurface->data = xwayland_view; | ||
473 | } | 480 | } |
474 | 481 | ||
475 | void handle_xwayland_ready(struct wl_listener *listener, void *data) { | 482 | void handle_xwayland_ready(struct wl_listener *listener, void *data) { |