From 721c3bc10182cacf1a98baddde3c94e59797ddb7 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Fri, 22 Dec 2006 19:10:43 +0000 Subject: Replace a lot of idle and timeout calls by the new gdk_threads api. 2006-12-22 Matthias Clasen * *.c: Replace a lot of idle and timeout calls by the new gdk_threads api. --- gtk/gtkrecentchooserdefault.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) (limited to 'gtk/gtkrecentchooserdefault.c') diff --git a/gtk/gtkrecentchooserdefault.c b/gtk/gtkrecentchooserdefault.c index 9a64f80d13..df8a70c564 100644 --- a/gtk/gtkrecentchooserdefault.c +++ b/gtk/gtkrecentchooserdefault.c @@ -754,8 +754,6 @@ load_recent_items (gpointer user_data) const gchar *uri, *name; gboolean retval; - GDK_THREADS_ENTER (); - impl = GTK_RECENT_CHOOSER_DEFAULT (user_data); g_assert ((impl->load_state == LOAD_EMPTY) || @@ -767,8 +765,6 @@ load_recent_items (gpointer user_data) impl->recent_items = gtk_recent_chooser_get_items (GTK_RECENT_CHOOSER (impl)); if (!impl->recent_items) { - GDK_THREADS_LEAVE (); - impl->load_state = LOAD_FINISHED; return FALSE; @@ -831,8 +827,6 @@ load_recent_items (gpointer user_data) retval = TRUE; } - GDK_THREADS_LEAVE (); - return retval; } @@ -841,8 +835,6 @@ cleanup_after_load (gpointer user_data) { GtkRecentChooserDefault *impl; - GDK_THREADS_ENTER (); - impl = GTK_RECENT_CHOOSER_DEFAULT (user_data); if (impl->load_id != 0) @@ -864,8 +856,6 @@ cleanup_after_load (gpointer user_data) (impl->load_state == LOAD_FINISHED)); set_busy_cursor (impl, FALSE); - - GDK_THREADS_LEAVE (); } /* clears the current model and reloads the recently used resources */ @@ -888,7 +878,7 @@ reload_recent_items (GtkRecentChooserDefault *impl) set_busy_cursor (impl, TRUE); impl->load_state = LOAD_EMPTY; - impl->load_id = g_idle_add_full (G_PRIORITY_HIGH_IDLE + 30, + impl->load_id = gdk_threads_add_idle_full (G_PRIORITY_HIGH_IDLE + 30, load_recent_items, impl, cleanup_after_load); -- cgit v1.2.1