From 2ce1e036cfbf6ded802897028f4b3b5ababa29e2 Mon Sep 17 00:00:00 2001 From: Sergio Villar Senin Date: Fri, 23 Jan 2009 09:24:34 +0000 Subject: [PATCH] * Fixes NB#99097, HW keyboard works with new folder dialog again pmo-trunk-r7251 --- src/hildon2/modest-platform.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/hildon2/modest-platform.c b/src/hildon2/modest-platform.c index c0690cf..7486622 100644 --- a/src/hildon2/modest-platform.c +++ b/src/hildon2/modest-platform.c @@ -564,18 +564,14 @@ entry_insert_text (GtkEditable *editable, g_free (msg); g_free (tmp); } else { - gint insert_length; - - insert_length = g_utf8_strlen (text, -1); - - if (insert_length + chars_length >= 20) { + if (length >= 20) { hildon_banner_show_information (gtk_widget_get_parent (GTK_WIDGET (data)), NULL, _CS("ckdg_ib_maximum_characters_reached")); } /* Write the text in the entry if it's valid */ g_signal_handlers_block_by_func (editable, (gpointer) entry_insert_text, data); - gtk_editable_insert_text (editable, text, MIN (chars_length + insert_length, 20), position); + gtk_editable_insert_text (editable, text, length, position); g_signal_handlers_unblock_by_func (editable, (gpointer) entry_insert_text, data); } -- 1.7.9.5