diff --git a/src/wayland/clientconnection.cpp b/src/wayland/clientconnection.cpp index 8e2152ee76..3068e7d651 100644 --- a/src/wayland/clientconnection.cpp +++ b/src/wayland/clientconnection.cpp @@ -68,6 +68,7 @@ void ClientConnectionPrivate::destroyListenerCallback(wl_listener *listener, voi Q_ASSERT(it != s_allClients.constEnd()); auto p = (*it); auto q = p->q; + emit q->aboutToBeDestroyed(); p->client = nullptr; wl_list_remove(&p->listener.link); emit q->disconnected(q); diff --git a/src/wayland/clientconnection.h b/src/wayland/clientconnection.h index c75db64947..d84b2c9105 100644 --- a/src/wayland/clientconnection.h +++ b/src/wayland/clientconnection.h @@ -123,6 +123,10 @@ public: void destroy(); Q_SIGNALS: + /** + * This signal is emitted when the client is about to be destroyed. + */ + void aboutToBeDestroyed(); /** * Signal emitted when the ClientConnection got disconnected from the server. */