diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/sway/server.h | 4 | ||||
-rw-r--r-- | include/sway/view.h | 16 |
2 files changed, 20 insertions, 0 deletions
diff --git a/include/sway/server.h b/include/sway/server.h index b0684d15..30b15e75 100644 --- a/include/sway/server.h +++ b/include/sway/server.h | |||
@@ -30,6 +30,9 @@ struct sway_server { | |||
30 | 30 | ||
31 | struct wlr_xdg_shell_v6 *xdg_shell_v6; | 31 | struct wlr_xdg_shell_v6 *xdg_shell_v6; |
32 | struct wl_listener xdg_shell_v6_surface; | 32 | struct wl_listener xdg_shell_v6_surface; |
33 | |||
34 | struct wlr_xwayland *xwayland; | ||
35 | struct wl_listener xwayland_surface; | ||
33 | }; | 36 | }; |
34 | 37 | ||
35 | struct sway_server server; | 38 | struct sway_server server; |
@@ -42,5 +45,6 @@ void output_add_notify(struct wl_listener *listener, void *data); | |||
42 | void output_remove_notify(struct wl_listener *listener, void *data); | 45 | void output_remove_notify(struct wl_listener *listener, void *data); |
43 | 46 | ||
44 | void handle_xdg_shell_v6_surface(struct wl_listener *listener, void *data); | 47 | void handle_xdg_shell_v6_surface(struct wl_listener *listener, void *data); |
48 | void handle_xwayland_surface(struct wl_listener *listener, void *data); | ||
45 | 49 | ||
46 | #endif | 50 | #endif |
diff --git a/include/sway/view.h b/include/sway/view.h index cf2e6f66..2d9b4ef5 100644 --- a/include/sway/view.h +++ b/include/sway/view.h | |||
@@ -3,6 +3,7 @@ | |||
3 | #include <wayland-server.h> | 3 | #include <wayland-server.h> |
4 | #include <wlr/types/wlr_surface.h> | 4 | #include <wlr/types/wlr_surface.h> |
5 | #include <wlr/types/wlr_xdg_shell_v6.h> | 5 | #include <wlr/types/wlr_xdg_shell_v6.h> |
6 | #include <wlr/xwayland.h> | ||
6 | 7 | ||
7 | struct sway_container; | 8 | struct sway_container; |
8 | struct sway_view; | 9 | struct sway_view; |
@@ -19,6 +20,19 @@ struct sway_xdg_surface_v6 { | |||
19 | int pending_width, pending_height; | 20 | int pending_width, pending_height; |
20 | }; | 21 | }; |
21 | 22 | ||
23 | struct sway_xwayland_surface { | ||
24 | struct sway_view *view; | ||
25 | |||
26 | struct wl_listener commit; | ||
27 | struct wl_listener request_move; | ||
28 | struct wl_listener request_resize; | ||
29 | struct wl_listener request_maximize; | ||
30 | struct wl_listener request_configure; | ||
31 | struct wl_listener destroy; | ||
32 | |||
33 | int pending_width, pending_height; | ||
34 | }; | ||
35 | |||
22 | enum sway_view_type { | 36 | enum sway_view_type { |
23 | SWAY_WL_SHELL_VIEW, | 37 | SWAY_WL_SHELL_VIEW, |
24 | SWAY_XDG_SHELL_V6_VIEW, | 38 | SWAY_XDG_SHELL_V6_VIEW, |
@@ -46,10 +60,12 @@ struct sway_view { | |||
46 | 60 | ||
47 | union { | 61 | union { |
48 | struct wlr_xdg_surface_v6 *wlr_xdg_surface_v6; | 62 | struct wlr_xdg_surface_v6 *wlr_xdg_surface_v6; |
63 | struct wlr_xwayland_surface *wlr_xwayland_surface; | ||
49 | }; | 64 | }; |
50 | 65 | ||
51 | union { | 66 | union { |
52 | struct sway_xdg_surface_v6 *sway_xdg_surface_v6; | 67 | struct sway_xdg_surface_v6 *sway_xdg_surface_v6; |
68 | struct sway_xwayland_surface *sway_xwayland_surface; | ||
53 | }; | 69 | }; |
54 | 70 | ||
55 | struct { | 71 | struct { |