summaryrefslogtreecommitdiff
path: root/gtk/gtkspinbutton.c
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2006-12-22 19:10:43 +0000
committerMatthias Clasen <matthiasc@src.gnome.org>2006-12-22 19:10:43 +0000
commit721c3bc10182cacf1a98baddde3c94e59797ddb7 (patch)
tree78b2e3ae3c00133a58f09653aff664e4ab0305e9 /gtk/gtkspinbutton.c
parent7854bd1b6e6102aff426bf6a48606c4a9b12b7c2 (diff)
downloadgtk+-721c3bc10182cacf1a98baddde3c94e59797ddb7.tar.gz
Replace a lot of idle and timeout calls by the new gdk_threads api.
2006-12-22 Matthias Clasen <mclasen@redhat.com> * *.c: Replace a lot of idle and timeout calls by the new gdk_threads api.
Diffstat (limited to 'gtk/gtkspinbutton.c')
-rw-r--r--gtk/gtkspinbutton.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/gtk/gtkspinbutton.c b/gtk/gtkspinbutton.c
index bcd360bbc4..741924551e 100644
--- a/gtk/gtkspinbutton.c
+++ b/gtk/gtkspinbutton.c
@@ -112,7 +112,7 @@ static void gtk_spin_button_state_changed (GtkWidget *widget,
GtkStateType previous_state);
static void gtk_spin_button_draw_arrow (GtkSpinButton *spin_button,
GtkArrowType arrow_type);
-static gint gtk_spin_button_timer (GtkSpinButton *spin_button);
+static gboolean gtk_spin_button_timer (GtkSpinButton *spin_button);
static void gtk_spin_button_stop_spinning (GtkSpinButton *spin);
static void gtk_spin_button_value_changed (GtkAdjustment *adjustment,
GtkSpinButton *spin_button);
@@ -1036,7 +1036,7 @@ start_spinning (GtkSpinButton *spin,
spin->timer_step = step;
spin->need_timer = TRUE;
- spin->timer = g_timeout_add (timeout,
+ spin->timer = gdk_threads_add_timeout (timeout,
(GSourceFunc) gtk_spin_button_timer,
(gpointer) spin);
}
@@ -1176,8 +1176,6 @@ gtk_spin_button_timer (GtkSpinButton *spin_button)
{
gboolean retval = FALSE;
- GDK_THREADS_ENTER ();
-
if (spin_button->timer)
{
if (spin_button->click_child == GTK_ARROW_UP)
@@ -1193,7 +1191,7 @@ gtk_spin_button_timer (GtkSpinButton *spin_button)
g_object_get (settings, "gtk-timeout-repeat", &timeout, NULL);
spin_button->need_timer = FALSE;
- spin_button->timer = g_timeout_add (timeout,
+ spin_button->timer = gdk_threads_add_timeout (timeout,
(GSourceFunc) gtk_spin_button_timer,
(gpointer) spin_button);
}
@@ -1214,8 +1212,6 @@ gtk_spin_button_timer (GtkSpinButton *spin_button)
}
}
- GDK_THREADS_LEAVE ();
-
return retval;
}