[PATCH 7/9] clients: Add a widget_get_wl_subsurface

Neil Roberts neil at linux.intel.com
Mon Sep 9 08:41:43 PDT 2013


Adds a simple accessor for the wl_subsurface for widgets created with
window_add_subsurface.
---
 clients/window.c | 6 ++++++
 clients/window.h | 3 +++
 2 files changed, 9 insertions(+)

diff --git a/clients/window.c b/clients/window.c
index 6854745..a837ec8 100644
--- a/clients/window.c
+++ b/clients/window.c
@@ -1845,6 +1845,12 @@ widget_get_wl_surface(struct widget *widget)
 	return widget->surface->surface;
 }
 
+struct wl_subsurface *
+widget_get_wl_subsurface(struct widget *widget)
+{
+	return widget->surface->subsurface;
+}
+
 uint32_t
 widget_get_last_time(struct widget *widget)
 {
diff --git a/clients/window.h b/clients/window.h
index 4427ab5..6aaeb77 100644
--- a/clients/window.h
+++ b/clients/window.h
@@ -347,6 +347,9 @@ window_get_surface(struct window *window);
 struct wl_surface *
 window_get_wl_surface(struct window *window);
 
+struct wl_subsurface *
+widget_get_wl_subsurface(struct widget *widget);
+
 struct wl_shell_surface *
 window_get_wl_shell_surface(struct window *window);
 
-- 
1.8.3.1



More information about the wayland-devel mailing list