compositor: Add surface commit signal

Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
dev
Jonas Ådahl 9 years ago
parent 30d61d89c1
commit 5d9ca27aca
  1. 3
      libweston/compositor.c
  2. 1
      libweston/compositor.h

@ -455,6 +455,7 @@ weston_surface_create(struct weston_compositor *compositor)
return NULL;
wl_signal_init(&surface->destroy_signal);
wl_signal_init(&surface->commit_signal);
surface->compositor = compositor;
surface->ref_count = 1;
@ -2888,6 +2889,8 @@ weston_surface_commit_state(struct weston_surface *surface,
wl_list_insert_list(&surface->feedback_list,
&state->feedback_list);
wl_list_init(&state->feedback_list);
wl_signal_emit(&surface->commit_signal, surface);
}
static void

@ -1015,6 +1015,7 @@ struct weston_surface {
struct wl_resource *resource;
struct wl_signal destroy_signal; /* callback argument: this surface */
struct weston_compositor *compositor;
struct wl_signal commit_signal;
/** Damage in local coordinates from the client, for tex upload. */
pixman_region32_t damage;

Loading…
Cancel
Save