From c44f2ba91029a32ea6adaeedeb0ba23b3fa2bb62 Mon Sep 17 00:00:00 2001 From: Colin Leroy Date: Sun, 15 Mar 2009 10:31:10 +0000 Subject: [PATCH 1/1] 2009-03-15 [colin] 3.7.1cvs13 * src/gtk/gtkaspell.c Fix empty menu when there are no suggestions (using the Spelling menu) --- ChangeLog | 6 ++++++ PATCHSETS | 1 + configure.ac | 2 +- src/gtk/gtkaspell.c | 8 ++++---- 4 files changed, 12 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 079dcea2a..ff034c115 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2009-03-15 [colin] 3.7.1cvs13 + + * src/gtk/gtkaspell.c + Fix empty menu when there are no + suggestions (using the Spelling menu) + 2009-03-14 [colin] 3.7.1cvs12 * src/common/utils.c diff --git a/PATCHSETS b/PATCHSETS index 0eb39732b..b12b95652 100644 --- a/PATCHSETS +++ b/PATCHSETS @@ -3752,3 +3752,4 @@ ( cvs diff -u -r 1.94.2.202 -r 1.94.2.203 src/messageview.c; ) > 3.7.1cvs10.patchset ( cvs diff -u -r 1.60.2.57 -r 1.60.2.58 po/es.po; ) > 3.7.1cvs11.patchset ( cvs diff -u -r 1.36.2.166 -r 1.36.2.167 src/common/utils.c; ) > 3.7.1cvs12.patchset +( cvs diff -u -r 1.9.2.67 -r 1.9.2.68 src/gtk/gtkaspell.c; ) > 3.7.1cvs13.patchset diff --git a/configure.ac b/configure.ac index 208957f74..71b3d48d9 100644 --- a/configure.ac +++ b/configure.ac @@ -11,7 +11,7 @@ MINOR_VERSION=7 MICRO_VERSION=1 INTERFACE_AGE=0 BINARY_AGE=0 -EXTRA_VERSION=12 +EXTRA_VERSION=13 EXTRA_RELEASE= EXTRA_GTK2_VERSION= diff --git a/src/gtk/gtkaspell.c b/src/gtk/gtkaspell.c index f03870545..6957550f0 100644 --- a/src/gtk/gtkaspell.c +++ b/src/gtk/gtkaspell.c @@ -750,12 +750,12 @@ static GList *misspelled_suggest(GtkAspell *gtkaspell, gchar *word) gtkaspell_free_suggestions_list(gtkaspell); suggestions = enchant_dict_suggest(gtkaspell->gtkaspeller->speller, word, strlen(word), &num_sug); + list = g_list_append(list, g_strdup(word)); if (suggestions == NULL || num_sug == 0) { - gtkaspell->max_sug = - 1; - gtkaspell->suggestions_list = NULL; - return NULL; + gtkaspell->max_sug = -1; + gtkaspell->suggestions_list = list; + return list; } - list = g_list_append(list, g_strdup(word)); for (i = 0; i < num_sug; i++) list = g_list_append(list, g_strdup((gchar *)suggestions[i])); -- 2.25.1