aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/sway/tree/view.h4
-rw-r--r--sway/desktop/xwayland.c18
2 files changed, 11 insertions, 11 deletions
diff --git a/include/sway/tree/view.h b/include/sway/tree/view.h
index e5f53f4e..54f6d90e 100644
--- a/include/sway/tree/view.h
+++ b/include/sway/tree/view.h
@@ -28,8 +28,8 @@ struct sway_xwayland_surface {
28 struct wl_listener request_resize; 28 struct wl_listener request_resize;
29 struct wl_listener request_maximize; 29 struct wl_listener request_maximize;
30 struct wl_listener request_configure; 30 struct wl_listener request_configure;
31 struct wl_listener unmap_notify; 31 struct wl_listener unmap;
32 struct wl_listener map_notify; 32 struct wl_listener map;
33 struct wl_listener destroy; 33 struct wl_listener destroy;
34 34
35 int pending_width, pending_height; 35 int pending_width, pending_height;
diff --git a/sway/desktop/xwayland.c b/sway/desktop/xwayland.c
index 3e08b20e..13eaf79a 100644
--- a/sway/desktop/xwayland.c
+++ b/sway/desktop/xwayland.c
@@ -119,9 +119,9 @@ static void handle_destroy(struct wl_listener *listener, void *data) {
119 free(sway_surface); 119 free(sway_surface);
120} 120}
121 121
122static void handle_unmap_notify(struct wl_listener *listener, void *data) { 122static void handle_unmap(struct wl_listener *listener, void *data) {
123 struct sway_xwayland_surface *sway_surface = 123 struct sway_xwayland_surface *sway_surface =
124 wl_container_of(listener, sway_surface, unmap_notify); 124 wl_container_of(listener, sway_surface, unmap);
125 125
126 wl_list_remove(&sway_surface->view->unmanaged_view_link); 126 wl_list_remove(&sway_surface->view->unmanaged_view_link);
127 wl_list_init(&sway_surface->view->unmanaged_view_link); 127 wl_list_init(&sway_surface->view->unmanaged_view_link);
@@ -136,10 +136,10 @@ static void handle_unmap_notify(struct wl_listener *listener, void *data) {
136 sway_surface->view->surface = NULL; 136 sway_surface->view->surface = NULL;
137} 137}
138 138
139static void handle_map_notify(struct wl_listener *listener, void *data) { 139static void handle_map(struct wl_listener *listener, void *data) {
140 // TODO put the view back into the tree 140 // TODO put the view back into the tree
141 struct sway_xwayland_surface *sway_surface = 141 struct sway_xwayland_surface *sway_surface =
142 wl_container_of(listener, sway_surface, map_notify); 142 wl_container_of(listener, sway_surface, map);
143 struct wlr_xwayland_surface *xsurface = data; 143 struct wlr_xwayland_surface *xsurface = data;
144 144
145 sway_surface->view->surface = xsurface->surface; 145 sway_surface->view->surface = xsurface->surface;
@@ -221,11 +221,11 @@ void handle_xwayland_surface(struct wl_listener *listener, void *data) {
221 &sway_surface->request_configure); 221 &sway_surface->request_configure);
222 sway_surface->request_configure.notify = handle_configure_request; 222 sway_surface->request_configure.notify = handle_configure_request;
223 223
224 wl_signal_add(&xsurface->events.unmap_notify, &sway_surface->unmap_notify); 224 wl_signal_add(&xsurface->events.unmap, &sway_surface->unmap);
225 sway_surface->unmap_notify.notify = handle_unmap_notify; 225 sway_surface->unmap.notify = handle_unmap;
226 226
227 wl_signal_add(&xsurface->events.map_notify, &sway_surface->map_notify); 227 wl_signal_add(&xsurface->events.map, &sway_surface->map);
228 sway_surface->map_notify.notify = handle_map_notify; 228 sway_surface->map.notify = handle_map;
229 229
230 handle_map_notify(&sway_surface->map_notify, xsurface); 230 handle_map(&sway_surface->map, xsurface);
231} 231}