[PATCH weston v2 1/5] compositor: Change the definition of a surface being mapped
Jonas Ådahl
jadahl at gmail.com
Mon Jun 11 13:03:02 PDT 2012
Previously a surface was considered mapped when it had an output
assigned. This prevents a surface's animation to be suspended by setting
its output to NULL. A better definition which enables having headless
surfaces is a surface is mapped when it is in a layer.
Signed-off-by: Jonas Ådahl <jadahl at gmail.com>
---
src/compositor.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/src/compositor.c b/src/compositor.c
index 26c9a95..983e4f5 100644
--- a/src/compositor.c
+++ b/src/compositor.c
@@ -571,10 +571,7 @@ weston_surface_set_position(struct weston_surface *surface,
WL_EXPORT int
weston_surface_is_mapped(struct weston_surface *surface)
{
- if (surface->output)
- return 1;
- else
- return 0;
+ return !wl_list_empty(&surface->layer_link);
}
WL_EXPORT uint32_t
--
1.7.9.5
More information about the wayland-devel
mailing list