--- src/tools/metacity-window-demo.c.orig	Tue Jun 22 21:43:00 2010
+++ src/tools/metacity-window-demo.c	Wed May 18 19:33:39 2011
@@ -51,7 +51,11 @@ set_gdk_window_struts (GdkWindow *window,
   vals[11] = 800;
 
   XChangeProperty (GDK_WINDOW_XDISPLAY (window),
-                   GDK_WINDOW_XWINDOW (window),
+#ifdef HAVE_GTK_3
+                     GDK_WINDOW_XID (window),
+#else
+                     GDK_WINDOW_XWINDOW (window),
+#endif
                    XInternAtom (GDK_WINDOW_XDISPLAY (window),
                                 "_NET_WM_STRUT_PARTIAL", False),
                    XA_CARDINAL, 32, PropModeReplace,
@@ -118,7 +122,11 @@ set_gdk_window_type (GdkWindow  *window,
                           type, False);
   
   XChangeProperty (GDK_WINDOW_XDISPLAY (window),
+#ifdef HAVE_GTK_3
+                   GDK_WINDOW_XID (window),
+#else
                    GDK_WINDOW_XWINDOW (window),
+#endif
                    XInternAtom (GDK_WINDOW_XDISPLAY (window), "_NET_WM_WINDOW_TYPE", False),
                    XA_ATOM, 32, PropModeReplace,
                    (guchar *)atoms, 

--- src/wm-tester/main.c.orig	Tue Feb  9 13:42:01 2010
+++ src/wm-tester/main.c	Wed May 18 19:34:00 2011
@@ -120,7 +120,11 @@ evil_timeout (gpointer data)
       
       w = gtk_window_new (GTK_WINDOW_TOPLEVEL);
 
+#ifdef HAVE_GTK_3
+      gtk_window_move(GTK_WINDOW(w), 
+#else
       gtk_widget_set_uposition (w,
+#endif
                                 g_random_int_range (0,
                                                     gdk_screen_width ()),
                                 g_random_int_range (0,
