2007-12-15 Alp Toker <alp@atoker.com>
authoralp@webkit.org <alp@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 15 Dec 2007 14:13:15 +0000 (14:13 +0000)
committeralp@webkit.org <alp@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 15 Dec 2007 14:13:15 +0000 (14:13 +0000)
        GTK+ DRT build fix for GLib < 2.14.

        * DumpRenderTree/gtk/LayoutTestControllerGtk.cpp:
        (LayoutTestController::setWaitToDump):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@28753 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebKitTools/ChangeLog
WebKitTools/DumpRenderTree/gtk/LayoutTestControllerGtk.cpp

index 7509dc4d9e4f56db13ef52ac115810f7d2b70e9b..2dd1808b7c150cbcdd9c8ccbe5387172e490e62d 100644 (file)
@@ -1,3 +1,10 @@
+2007-12-15  Alp Toker  <alp@atoker.com>
+
+        GTK+ DRT build fix for GLib < 2.14.
+
+        * DumpRenderTree/gtk/LayoutTestControllerGtk.cpp:
+        (LayoutTestController::setWaitToDump):
+
 2007-12-05  Mark Rowe  <mrowe@apple.com>
 
         Reviewed by Alp Toker.
index 944a17fb9b4084eb39980e50469eb62e9c2af973..60446a5c5bfea292083fd348ddce610e08296708 100644 (file)
@@ -162,9 +162,15 @@ static gboolean waitToDumpWatchdogFired(void*)
 
 void LayoutTestController::setWaitToDump(bool waitUntilDone)
 {
+    static const int timeoutSeconds = 10;
+
     m_waitToDump = waitUntilDone;
     if (m_waitToDump && !waitToDumpWatchdog)
-        waitToDumpWatchdog = g_timeout_add_seconds(10, waitToDumpWatchdogFired, 0);
+#if GLIB_CHECK_VERSION(2,14,0)
+        waitToDumpWatchdog = g_timeout_add_seconds(timeoutSeconds, waitToDumpWatchdogFired, 0);
+#else
+        waitToDumpWatchdog = g_timeout_add(timeoutSeconds * 1000, waitToDumpWatchdogFired, 0);
+#endif
 }
 
 int LayoutTestController::windowCount()