aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRadek Doulik <rodo@ximian.com>2003-03-19 22:37:32 +0800
committerRadek Doulik <rodo@src.gnome.org>2003-03-19 22:37:32 +0800
commitafc9db89eb31929485a0de1b247f4f1431eb9b0e (patch)
tree007b4f6f631ea95d134ab1a4f802fe366b6f0766
parent30231895d1ff40a8eaa67383a697c06540ed3196 (diff)
downloadgsoc2013-evolution-afc9db89eb31929485a0de1b247f4f1431eb9b0e.tar.gz
gsoc2013-evolution-afc9db89eb31929485a0de1b247f4f1431eb9b0e.tar.zst
gsoc2013-evolution-afc9db89eb31929485a0de1b247f4f1431eb9b0e.zip
changed default language to en_us instead of en
2003-03-19 Radek Doulik <rodo@ximian.com> * mail-composer-prefs.c (spell_load_values): changed default language to en_us instead of en (spell_language_button_press): new handler, ported from 1.2 (spell_setup): use spell_language_enable and spell_language_button_press svn path=/trunk/; revision=20356
-rw-r--r--mail/ChangeLog8
-rw-r--r--mail/mail-composer-prefs.c27
2 files changed, 34 insertions, 1 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index d2471db503..49a4f03e88 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,11 @@
+2003-03-19 Radek Doulik <rodo@ximian.com>
+
+ * mail-composer-prefs.c (spell_load_values): changed default
+ language to en_us instead of en
+ (spell_language_button_press): new handler, ported from 1.2
+ (spell_setup): use spell_language_enable and
+ spell_language_button_press
+
2003-03-18 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (composer_get_message):
diff --git a/mail/mail-composer-prefs.c b/mail/mail-composer-prefs.c
index f35306aa2d..1dcef65b39 100644
--- a/mail/mail-composer-prefs.c
+++ b/mail/mail-composer-prefs.c
@@ -565,7 +565,7 @@ spell_load_values (MailComposerPrefs *prefs)
GConfValue *val;
char *def_lang;
- def_lang = g_strdup ("en");
+ def_lang = g_strdup (_("en_us"));
g_free (prefs->language_str);
prefs->language_str = g_strdup (def_lang);
prefs->spell_error_color.red = 0xffff;
@@ -668,6 +668,28 @@ spell_language_enable (GtkWidget *widget, MailComposerPrefs *prefs)
}
}
+static gboolean
+spell_language_button_press (GtkTreeView *tv, GdkEventButton *event, MailComposerPrefs *prefs)
+{
+ GtkTreePath *path = NULL;
+ GtkTreeViewColumn *column = NULL;
+ gtk_tree_view_get_path_at_pos (tv, event->x, event->y, &path, &column, NULL, NULL);
+
+ if (path != NULL && column != NULL && !strcmp (gtk_tree_view_column_get_title (column), _("Enabled"))) {
+ GtkTreeIter iter;
+ GtkTreeModel *model;
+ gboolean enabled;
+
+ model = gtk_tree_view_get_model (tv);
+ gtk_tree_model_get_iter (model, &iter, path);
+ gtk_tree_model_get (model, &iter, 0, &enabled, -1);
+ gtk_list_store_set ((GtkListStore *) model, &iter, 0, !enabled, -1);
+ spell_changed (prefs);
+ }
+
+ return FALSE;
+}
+
static void
spell_setup (MailComposerPrefs *prefs)
{
@@ -691,6 +713,9 @@ spell_setup (MailComposerPrefs *prefs)
spell_set_ui (prefs);
glade_xml_signal_connect_data (prefs->gui, "spellColorSet", G_CALLBACK (spell_color_set), prefs);
+ glade_xml_signal_connect_data (prefs->gui, "spellLanguageEnable", GTK_SIGNAL_FUNC (spell_language_enable), prefs);
+
+ g_signal_connect (prefs->language, "button_press_event", G_CALLBACK (spell_language_button_press), prefs);
}
static gboolean