[evolution/webkit-composer: 145/147] editor_actions_setup_languages_menu: Initialize active states.
- From: Matthew Barnes <mbarnes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/webkit-composer: 145/147] editor_actions_setup_languages_menu: Initialize active states.
- Date: Mon, 21 Jan 2013 02:22:19 +0000 (UTC)
commit 1f84194941da67b3d4339ace75b888f107a455fa
Author: Matthew Barnes <mbarnes redhat com>
Date: Sun Jan 20 16:21:23 2013 -0500
editor_actions_setup_languages_menu: Initialize active states.
e-util/e-editor-actions.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/e-util/e-editor-actions.c b/e-util/e-editor-actions.c
index 7e266c2..17b209e 100644
--- a/e-util/e-editor-actions.c
+++ b/e-util/e-editor-actions.c
@@ -1660,6 +1660,7 @@ editor_actions_setup_languages_menu (EEditor *editor)
for (link = list; link != NULL; link = g_list_next (link)) {
ESpellDictionary *dictionary = link->data;
GtkToggleAction *action;
+ gboolean active;
action = gtk_toggle_action_new (
e_spell_dictionary_get_code (dictionary),
@@ -1670,6 +1671,11 @@ editor_actions_setup_languages_menu (EEditor *editor)
action, "toggled",
G_CALLBACK (action_language_cb), editor);
+ /* Do this AFTER connecting to the "toggled" signal. */
+ active = e_spell_checker_get_language_active (
+ checker, e_spell_dictionary_get_code (dictionary));
+ gtk_toggle_action_set_active (action, active);
+
gtk_action_group_add_action (
action_group, GTK_ACTION (action));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]