]> Pileus Git - ~andy/gtk/blobdiff - tests/autotestfilesystem.c
Build more testapps, use G_PI instead of M_PI
[~andy/gtk] / tests / autotestfilesystem.c
index 33bd6ba4b00f20a1c29c4c9ed00642ad3abf8677..ccc679545317b731ebb24955e9284733ad3a60ef 100644 (file)
 
 #define GTK_FILE_SYSTEM_ENABLE_UNSUPPORTED
 
-#include <config.h>
+#include "config.h"
 #include <string.h>
+#ifdef HAVE_UNISTD_H
 #include <unistd.h>
+#endif
 #include <glib/gprintf.h>
 #include <gtk/gtk.h>
 #include <gtk/gtkfilesystem.h>
 
+#ifdef G_OS_WIN32
+#include <direct.h>
+#define rmdir(d) _rmdir(d)
+#endif
+
 #define CALLBACK_TIMEOUT_MS 3000       /* Period after which the callback must have been called */
 #define CANCEL_TIMEOUT_MS 100          /* We'll sleep for this much time before cancelling */
 
@@ -105,7 +112,7 @@ timeout_cb (gpointer data)
 static void
 wait_for_callback (TestCallbackClosure *closure)
 {
-  g_timeout_add (CALLBACK_TIMEOUT_MS, timeout_cb, closure);
+  gdk_threads_add_timeout (CALLBACK_TIMEOUT_MS, timeout_cb, closure);
   gtk_main ();
 }