wayland-surface: Adds _get_surface function

This adds a clutter_wayland_surface_get_surface() function for querying
the struct wl_surface * associated with a ClutterWaylandSurface.

Reviewed-by: Neil Roberts <neil@linux.intel.com>
Reviewed-by: Emmanuele Bassi <ebassi@linux.intel.com>
This commit is contained in:
Robert Bragg 2012-01-09 19:16:21 +00:00 committed by Neil Roberts
parent 83b94ec27d
commit 0ba6127edc
2 changed files with 9 additions and 1 deletions

View File

@ -213,7 +213,14 @@ set_size (ClutterWaylandSurface *self,
} }
} }
static void struct wl_surface *
clutter_wayland_surface_get_surface (ClutterWaylandSurface *self)
{
ClutterWaylandSurfacePrivate *priv = self->priv;
return priv->surface;
}
void
clutter_wayland_surface_set_surface (ClutterWaylandSurface *self, clutter_wayland_surface_set_surface (ClutterWaylandSurface *self,
struct wl_surface *surface) struct wl_surface *surface)
{ {

View File

@ -81,6 +81,7 @@ GType clutter_wayland_surface_get_type (void) G_GNUC_CONST;
ClutterActor *clutter_wayland_surface_new (struct wl_surface *surface); ClutterActor *clutter_wayland_surface_new (struct wl_surface *surface);
void clutter_wayland_surface_set_surface (ClutterWaylandSurface *self, void clutter_wayland_surface_set_surface (ClutterWaylandSurface *self,
struct wl_surface *surface); struct wl_surface *surface);
struct wl_surface *clutter_wayland_surface_get_surface (ClutterWaylandSurface *self);
gboolean clutter_wayland_surface_attach_buffer (ClutterWaylandSurface *self, gboolean clutter_wayland_surface_attach_buffer (ClutterWaylandSurface *self,
struct wl_buffer *buffer, struct wl_buffer *buffer,
GError **error); GError **error);