aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/wlr/types/wlr_data_device.h1
-rw-r--r--include/wlr/types/wlr_surface.h12
-rw-r--r--include/wlr/types/wlr_wl_shell.h2
-rw-r--r--include/wlr/types/wlr_xdg_shell_v6.h2
-rw-r--r--include/wlr/xwayland.h1
5 files changed, 12 insertions, 6 deletions
diff --git a/include/wlr/types/wlr_data_device.h b/include/wlr/types/wlr_data_device.h
index 4893bbf4..92d15972 100644
--- a/include/wlr/types/wlr_data_device.h
+++ b/include/wlr/types/wlr_data_device.h
@@ -73,7 +73,6 @@ struct wlr_drag_icon {
} events;
struct wl_listener surface_destroy;
- struct wl_listener surface_commit;
struct wl_listener seat_client_destroy;
};
diff --git a/include/wlr/types/wlr_surface.h b/include/wlr/types/wlr_surface.h
index c8e3761a..9f88d044 100644
--- a/include/wlr/types/wlr_surface.h
+++ b/include/wlr/types/wlr_surface.h
@@ -77,6 +77,10 @@ struct wlr_surface {
struct wl_listener compositor_listener;
void *compositor_data;
+ // surface commit callback for the role that runs before all others
+ void (*role_committed)(struct wlr_surface *surface, void *role_data);
+ void *role_data;
+
// subsurface properties
struct wlr_subsurface *subsurface;
struct wl_list subsurface_list; // wlr_subsurface::parent_link
@@ -146,4 +150,12 @@ void wlr_surface_send_leave(struct wlr_surface *surface,
void wlr_surface_send_frame_done(struct wlr_surface *surface,
const struct timespec *when);
+/**
+ * Set a callback for surface commit that runs before all the other callbacks.
+ * This is intended for use by the surface role.
+ */
+void wlr_surface_set_role_committed(struct wlr_surface *surface,
+ void (*role_committed)(struct wlr_surface *surface, void *role_data),
+ void *role_data);
+
#endif
diff --git a/include/wlr/types/wlr_wl_shell.h b/include/wlr/types/wlr_wl_shell.h
index 29446b04..375477c7 100644
--- a/include/wlr/types/wlr_wl_shell.h
+++ b/include/wlr/types/wlr_wl_shell.h
@@ -70,7 +70,6 @@ struct wlr_wl_shell_surface {
char *class;
struct wl_listener surface_destroy_listener;
- struct wl_listener surface_commit_listener;
struct wlr_wl_shell_surface *parent;
struct wl_list popup_link;
@@ -79,7 +78,6 @@ struct wlr_wl_shell_surface {
struct {
struct wl_signal destroy;
- struct wl_signal commit;
struct wl_signal ping_timeout;
struct wl_signal request_move;
diff --git a/include/wlr/types/wlr_xdg_shell_v6.h b/include/wlr/types/wlr_xdg_shell_v6.h
index b723a950..280bea27 100644
--- a/include/wlr/types/wlr_xdg_shell_v6.h
+++ b/include/wlr/types/wlr_xdg_shell_v6.h
@@ -122,10 +122,8 @@ struct wlr_xdg_surface_v6 {
struct wlr_box *geometry;
struct wl_listener surface_destroy_listener;
- struct wl_listener surface_commit_listener;
struct {
- struct wl_signal commit;
struct wl_signal destroy;
struct wl_signal ping_timeout;
diff --git a/include/wlr/xwayland.h b/include/wlr/xwayland.h
index 230cfeed..37b09204 100644
--- a/include/wlr/xwayland.h
+++ b/include/wlr/xwayland.h
@@ -134,7 +134,6 @@ struct wlr_xwayland_surface {
} events;
struct wl_listener surface_destroy;
- struct wl_listener surface_commit;
void *data;
};