aboutsummaryrefslogtreecommitdiff
path: root/main.c
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2019-10-27 15:01:03 +0000
committerDaniel Eklöf <daniel@ekloef.se>2019-10-27 15:01:44 +0000
commit9e6c28f5b6b0be6788d91bf3233323362cac732a (patch)
tree2679ba4860ce5479cb45c8d0b69b64967575781e /main.c
parentwayland: implement wayl_destroy() (diff)
wayland: implement wayl_win_destroy()
Diffstat (limited to 'main.c')
-rw-r--r--main.c23
1 files changed, 3 insertions, 20 deletions
diff --git a/main.c b/main.c
index 7487705f..267bd89f 100644
--- a/main.c
+++ b/main.c
@@ -463,7 +463,7 @@ fdm_ptmx(struct fdm *fdm, int fd, int events, void *data)
* ourselves we just received keyboard input, and in
* this case *not* delay rendering?
*/
- if (term->render.frame_callback == NULL) {
+ if (term->window.frame_callback == NULL) {
/* First timeout - reset each time we receive input. */
timerfd_settime(
term->delayed_render_timer.lower_fd, 0,
@@ -1151,7 +1151,6 @@ out:
shm_fini();
- tll_free(term.window.on_outputs);
if (term.selection.clipboard.data_source != NULL)
wl_data_source_destroy(term.selection.clipboard.data_source);
if (term.selection.clipboard.data_offer != NULL)
@@ -1172,24 +1171,8 @@ out:
xkb_state_unref(term.kbd.xkb_state);
if (term.kbd.xkb != NULL)
xkb_context_unref(term.kbd.xkb);
- if (term.window.search_sub_surface != NULL)
- wl_subsurface_destroy(term.window.search_sub_surface);
- if (term.window.search_surface != NULL)
- wl_surface_destroy(term.window.search_surface);
- if (term.render.frame_callback != NULL)
- wl_callback_destroy(term.render.frame_callback);
- if (term.window.xdg_toplevel_decoration != NULL)
- zxdg_toplevel_decoration_v1_destroy(term.window.xdg_toplevel_decoration);
- if (term.window.xdg_decoration_manager != NULL)
- zxdg_decoration_manager_v1_destroy(term.window.xdg_decoration_manager);
- if (term.window.xdg_toplevel != NULL)
- xdg_toplevel_destroy(term.window.xdg_toplevel);
- if (term.window.xdg_surface != NULL)
- xdg_surface_destroy(term.window.xdg_surface);
- if (term.window.shell != NULL)
- xdg_wm_base_destroy(term.window.shell);
- if (term.window.surface != NULL)
- wl_surface_destroy(term.window.surface);
+
+ wayl_win_destroy(&term.window);
wayl_destroy(&term.wl);
free(term.vt.osc.data);