diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/sway/server.h | 9 | ||||
-rw-r--r-- | include/sway/xwayland.h | 25 |
2 files changed, 28 insertions, 6 deletions
diff --git a/include/sway/server.h b/include/sway/server.h index 65d96e7a..96cad69d 100644 --- a/include/sway/server.h +++ b/include/sway/server.h | |||
@@ -11,7 +11,7 @@ | |||
11 | #include <wlr/types/wlr_xdg_shell.h> | 11 | #include <wlr/types/wlr_xdg_shell.h> |
12 | #include <wlr/render/wlr_renderer.h> | 12 | #include <wlr/render/wlr_renderer.h> |
13 | // TODO WLR: make Xwayland optional | 13 | // TODO WLR: make Xwayland optional |
14 | #include <wlr/xwayland.h> | 14 | #include "sway/xwayland.h" |
15 | 15 | ||
16 | struct sway_server { | 16 | struct sway_server { |
17 | struct wl_display *wl_display; | 17 | struct wl_display *wl_display; |
@@ -37,12 +37,9 @@ struct sway_server { | |||
37 | struct wlr_xdg_shell *xdg_shell; | 37 | struct wlr_xdg_shell *xdg_shell; |
38 | struct wl_listener xdg_shell_surface; | 38 | struct wl_listener xdg_shell_surface; |
39 | 39 | ||
40 | struct wlr_xwayland *xwayland; | 40 | struct sway_xwayland xwayland; |
41 | struct wlr_xcursor_manager *xcursor_manager; | ||
42 | struct wl_listener xwayland_surface; | 41 | struct wl_listener xwayland_surface; |
43 | 42 | struct wl_listener xwayland_ready; | |
44 | struct wlr_wl_shell *wl_shell; | ||
45 | struct wl_listener wl_shell_surface; | ||
46 | }; | 43 | }; |
47 | 44 | ||
48 | struct sway_server server; | 45 | struct sway_server server; |
diff --git a/include/sway/xwayland.h b/include/sway/xwayland.h new file mode 100644 index 00000000..78d1053b --- /dev/null +++ b/include/sway/xwayland.h | |||
@@ -0,0 +1,25 @@ | |||
1 | #ifndef SWAY_XWAYLAND_H | ||
2 | #define SWAY_XWAYLAND_H | ||
3 | |||
4 | #include <wlr/xwayland.h> | ||
5 | #include <xcb/xproto.h> | ||
6 | |||
7 | enum atom_name { | ||
8 | NET_WM_WINDOW_TYPE_DIALOG, | ||
9 | NET_WM_WINDOW_TYPE_UTILITY, | ||
10 | NET_WM_WINDOW_TYPE_TOOLBAR, | ||
11 | NET_WM_WINDOW_TYPE_SPLASH, | ||
12 | NET_WM_STATE_MODAL, | ||
13 | ATOM_LAST, | ||
14 | }; | ||
15 | |||
16 | struct sway_xwayland { | ||
17 | struct wlr_xwayland *wlr_xwayland; | ||
18 | struct wlr_xcursor_manager *xcursor_manager; | ||
19 | |||
20 | xcb_atom_t atoms[ATOM_LAST]; | ||
21 | }; | ||
22 | |||
23 | void handle_xwayland_ready(struct wl_listener *listener, void *data); | ||
24 | |||
25 | #endif | ||