[clutter/wip/wayland: 17/45] test-wayland-surface: forward damage to surface actor



commit 294e2a1bd65061b5c8ef7e9debf3a4b9b078df58
Author: Robert Bragg <robert linux intel com>
Date:   Mon Jan 9 19:06:05 2012 +0000

    test-wayland-surface: forward damage to surface actor
    
    This ensures we now forward the damage events from clients onto the
    corresponding ClutterWaylandSurface actors.

 tests/interactive/test-wayland-surface.c |   11 ++++++++++-
 1 files changed, 10 insertions(+), 1 deletions(-)
---
diff --git a/tests/interactive/test-wayland-surface.c b/tests/interactive/test-wayland-surface.c
index 88d4278..0068361 100644
--- a/tests/interactive/test-wayland-surface.c
+++ b/tests/interactive/test-wayland-surface.c
@@ -339,12 +339,21 @@ tws_surface_attach_buffer (struct wl_client *wayland_client,
 
 static void
 tws_surface_damage (struct wl_client *client,
-                    struct wl_resource *resource,
+                    struct wl_resource *surface_resource,
                     gint32 x,
                     gint32 y,
                     gint32 width,
                     gint32 height)
 {
+  TWSSurface *surface = surface_resource->data;
+  if (surface->buffer)
+    {
+      clutter_wayland_surface_damage_buffer (CLUTTER_WAYLAND_SURFACE (surface->actor),
+                                             surface->buffer->wayland_buffer,
+                                             x, y, width, height);
+    }
+  g_warning ("Damage");
+
 }
 
 static void



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]