summaryrefslogtreecommitdiff
path: root/gtk/gtkspinbutton.c
diff options
context:
space:
mode:
authorWilliam Jon McCann <william.jon.mccann@gmail.com>2013-07-09 16:44:04 -0400
committerWilliam Jon McCann <william.jon.mccann@gmail.com>2013-07-11 17:08:15 -0400
commit57fc8763e930911f97b6e9fc9edebafb887db2b3 (patch)
tree34e928277f9b2fa4c5fd3e6e4526967c4e0a66a9 /gtk/gtkspinbutton.c
parent0efeb96dab93f93e15137f5b16a0132e7c9f4369 (diff)
downloadgtk+-57fc8763e930911f97b6e9fc9edebafb887db2b3.tar.gz
Deprecate and ignore the timeout-initial and timeout-repeat settings
Diffstat (limited to 'gtk/gtkspinbutton.c')
-rw-r--r--gtk/gtkspinbutton.c17
1 files changed, 4 insertions, 13 deletions
diff --git a/gtk/gtkspinbutton.c b/gtk/gtkspinbutton.c
index 7af3c48367..13d29d4cd6 100644
--- a/gtk/gtkspinbutton.c
+++ b/gtk/gtkspinbutton.c
@@ -58,7 +58,8 @@
#define EPSILON 1e-10
#define MAX_DIGITS 20
#define MIN_ARROW_WIDTH 6
-
+#define TIMEOUT_INITIAL 500
+#define TIMEOUT_REPEAT 50
/**
* SECTION:gtkspinbutton
@@ -1459,14 +1460,9 @@ start_spinning (GtkSpinButton *spin,
if (!priv->timer)
{
- GtkSettings *settings = gtk_widget_get_settings (GTK_WIDGET (spin));
- guint timeout;
-
- g_object_get (settings, "gtk-timeout-initial", &timeout, NULL);
-
priv->timer_step = step;
priv->need_timer = TRUE;
- priv->timer = gdk_threads_add_timeout (timeout,
+ priv->timer = gdk_threads_add_timeout (TIMEOUT_INITIAL,
(GSourceFunc) gtk_spin_button_timer,
(gpointer) spin);
}
@@ -1590,13 +1586,8 @@ gtk_spin_button_timer (GtkSpinButton *spin_button)
if (priv->need_timer)
{
- GtkSettings *settings = gtk_widget_get_settings (GTK_WIDGET (spin_button));
- guint timeout;
-
- g_object_get (settings, "gtk-timeout-repeat", &timeout, NULL);
-
priv->need_timer = FALSE;
- priv->timer = gdk_threads_add_timeout (timeout,
+ priv->timer = gdk_threads_add_timeout (TIMEOUT_REPEAT,
(GSourceFunc) gtk_spin_button_timer,
(gpointer) spin_button);
}