From 952312024182b47fd028517a3afdc17e515e196d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20=C3=85dahl?= Date: Wed, 3 Mar 2021 17:21:59 +0100 Subject: [PATCH] x11/events: Use MetaContext to terminate instead of meta_quit() Part-of: --- src/x11/events.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/x11/events.c b/src/x11/events.c index 6c83743e7..9dec73a9b 100644 --- a/src/x11/events.c +++ b/src/x11/events.c @@ -39,8 +39,8 @@ #include "core/meta-workspace-manager-private.h" #include "core/window-private.h" #include "core/workspace-private.h" -#include "meta/main.h" #include "meta/meta-backend.h" +#include "meta/meta-context.h" #include "meta/meta-x11-errors.h" #include "x11/meta-startup-notification-x11.h" #include "x11/meta-x11-display-private.h" @@ -1146,11 +1146,13 @@ static gboolean close_display_idle_cb (gpointer user_data) { MetaX11Display *x11_display = META_X11_DISPLAY (user_data); + MetaDisplay *display = x11_display->display; + MetaContext *context = meta_display_get_context (display); - meta_display_close (x11_display->display, + meta_display_close (display, x11_display->xselectionclear_timestamp); x11_display->display_close_idle = 0; - meta_quit (META_EXIT_SUCCESS); + meta_context_terminate (context); return G_SOURCE_REMOVE; }