summaryrefslogtreecommitdiffstats
path: root/src/ivi-compositor.h
diff options
context:
space:
mode:
authorMarius Vlad <marius.vlad@collabora.com>2022-08-03 16:14:17 +0300
committerMarius Vlad <marius.vlad@collabora.com>2022-08-31 23:07:05 +0300
commit3e72564852a6f34120311091d1208f61bcd641f4 (patch)
treeac052ca708ac696aebc325d62783809ab12f4518 /src/ivi-compositor.h
parentf96fc9e91ab950c674a11a056be7d2d475e6b2d7 (diff)
agl-shell: Add bound_ok and bound_fail events and a default destructor
As we're increasing the amount of combinations we could have in the AGL platforms, in which we're mixing various platforms, we require a way to tell clients that there's already a shell client which in charge. We can't really have multiple shell clients managing the windows and surfaces, but in the same time we don't want to sever the wayland connection the way it happens currently. Racy alternatives might exist, which avoid advertising the interface altogether once a client did bind to the interface but that's not really a viable solution. So instead of doing that, this patch introduces two new events which tells the client that it was either successful, and it can continue issue requests and receive events or a that it the bind failed. The client can chose to wait and try later and abandon to bind to the agl_shell intefface, and behave like a regular client. While doing an update to protocol to add those two events this patch add also a default destructor for the protocol. Bug-AGL: SPEC-4502 Signed-off-by: Marius Vlad <marius.vlad@collabora.com> Change-Id: Iacb86a668d1c4630724eecdb18e4b4c2d4e8e34a
Diffstat (limited to 'src/ivi-compositor.h')
-rw-r--r--src/ivi-compositor.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/ivi-compositor.h b/src/ivi-compositor.h
index 78d1acd..dff11b9 100644
--- a/src/ivi-compositor.h
+++ b/src/ivi-compositor.h
@@ -46,6 +46,11 @@ struct desktop_client {
struct wl_list link; /* ivi_compositor::desktop_clients */
};
+enum agl_shell_bound_status {
+ BOUND_OK,
+ BOUND_FAILED,
+};
+
struct ivi_compositor {
struct weston_compositor *compositor;
struct weston_config *config;
@@ -81,6 +86,7 @@ struct ivi_compositor {
struct wl_client *client;
struct wl_resource *resource;
bool ready;
+ enum agl_shell_bound_status status;
} shell_client;
struct wl_list desktop_clients; /* desktop_client::link */