From c04c884f3516ca7408fd737536a2721554dc7f71 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Thu, 31 Jul 2008 22:27:02 +0000 Subject: [PATCH] Use a second-granularity timer. svn path=/trunk/; revision=20922 --- ChangeLog | 3 +++ modules/input/gtkimcontextmultipress.c | 3 +-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 19b7f49cc0..50060acf51 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2008-07-31 Matthisa Clasen + * modules/input/gtkimcontextmultipress.c: Use a second-granularity + timer for automatic commit. + * gtk/gtkclipboard.c (gtk_clipboard_store): Use a second-grandularity timer for the store timeout. diff --git a/modules/input/gtkimcontextmultipress.c b/modules/input/gtkimcontextmultipress.c index 427deed72b..f745075784 100644 --- a/modules/input/gtkimcontextmultipress.c +++ b/modules/input/gtkimcontextmultipress.c @@ -378,8 +378,7 @@ vfunc_filter_keypress (GtkIMContext *context, GdkEventKey *event) /* Create a timeout that will cause the currently chosen character to be committed, * if nothing happens for a certain amount of time: */ - /* g_timeout_add_seconds is only available since glib 2.14: multipress_context->timeout_id = g_timeout_add_seconds(AUTOMATIC_COMPOSE_TIMEOUT, on_timeout, multipress_context); */ - multipress_context->timeout_id = g_timeout_add (AUTOMATIC_COMPOSE_TIMEOUT * 1000, on_timeout, multipress_context); + multipress_context->timeout_id = g_timeout_add_seconds(AUTOMATIC_COMPOSE_TIMEOUT, on_timeout, multipress_context); return TRUE; /* TRUE means that the event was handled. */ }