evolution r35324 - trunk/mail



Author: mbarnes
Date: Sun Apr  6 02:13:37 2008
New Revision: 35324
URL: http://svn.gnome.org/viewvc/evolution?rev=35324&view=rev

Log:
2008-04-05  Matthew Barnes  <mbarnes redhat com>

	* mail/em-composer-prefs.c:
	Fix a corner case that I missed in my last commit.



Modified:
   trunk/mail/ChangeLog
   trunk/mail/em-composer-prefs.c
   trunk/mail/em-format-html.c
   trunk/mail/em-format-quote.c

Modified: trunk/mail/em-composer-prefs.c
==============================================================================
--- trunk/mail/em-composer-prefs.c	(original)
+++ trunk/mail/em-composer-prefs.c	Sun Apr  6 02:13:37 2008
@@ -558,12 +558,9 @@
                            const gchar *path_string,
                            EMComposerPrefs *prefs)
 {
-	GSList *list = NULL;
-	GConfClient *client;
 	GtkTreeModel *model;
 	GtkTreePath *path;
 	GtkTreeIter iter;
-	const gchar *key;
 	gboolean active;
 	gboolean valid;
 
@@ -578,6 +575,19 @@
 	/* Toggle the active state. */
 	gtk_tree_model_get (model, &iter, 0, &active, -1);
 	gtk_list_store_set (GTK_LIST_STORE (model), &iter, 0, !active, -1);
+}
+
+static void
+spell_language_save (EMComposerPrefs *prefs)
+{
+	GSList *list = NULL;
+	GConfClient *client;
+	GtkTreeModel *model;
+	GtkTreeIter iter;
+	const gchar *key;
+	gboolean valid;
+
+	model = prefs->language_model;
 
 	/* Build a list of active languages. */
 	valid = gtk_tree_model_get_iter_first (model, &iter);
@@ -662,6 +672,9 @@
 		available_languages = available_languages->next;
 	}
 
+	/* Update the GConf list in case we used a default language. */
+	spell_language_save (prefs);
+
 	g_slist_free (active_languages);
 
 	key = "/apps/evolution/mail/composer/spell_color";
@@ -944,13 +957,16 @@
 		"/apps/evolution/mail/composer/charset");
 	g_free (buf);
 
-	/* Spell Checking: GNOME Spell part */
+	/* Spell Checking */
 	widget = glade_xml_get_widget (gui, "colorButtonSpellCheckColor");
 	prefs->color = GTK_COLOR_BUTTON (widget);
 	widget = glade_xml_get_widget (gui, "listSpellCheckLanguage");
 	view = GTK_TREE_VIEW (widget);
 	store = gtk_list_store_new (
 		3, G_TYPE_BOOLEAN, G_TYPE_STRING, G_TYPE_POINTER);
+	g_signal_connect_swapped (
+		store, "row-changed",
+		G_CALLBACK (spell_language_save), prefs);
 	prefs->language_model = GTK_TREE_MODEL (store);
 	gtk_tree_view_set_model (view, prefs->language_model);
 	renderer = gtk_cell_renderer_toggle_new ();

Modified: trunk/mail/em-format-html.c
==============================================================================
--- trunk/mail/em-format-html.c	(original)
+++ trunk/mail/em-format-html.c	Sun Apr  6 02:13:37 2008
@@ -1673,7 +1673,7 @@
 efh_format_header(EMFormat *emf, CamelStream *stream, CamelMedium *part, struct _camel_header_raw *header, guint32 flags, const char *charset)
 {
 	EMFormatHTML *efh = (EMFormatHTML *)emf;
-	char *name, *buf, *value = NULL, *p;
+	char *name, *buf, *value = NULL;
 	const char *label, *txt;
 	gboolean addrspec = FALSE;
 	char *str_field = NULL;

Modified: trunk/mail/em-format-quote.c
==============================================================================
--- trunk/mail/em-format-quote.c	(original)
+++ trunk/mail/em-format-quote.c	Sun Apr  6 02:13:37 2008
@@ -295,7 +295,7 @@
 {
 	CamelMimeMessage *msg = (CamelMimeMessage *) part;
 	EMFormatQuote *emfq = (EMFormatQuote *) emf;
-	char *name, *buf, *value = NULL, *p;
+	char *name, *buf, *value = NULL;
 	const char *txt, *label;
 	gboolean addrspec = FALSE;
 	int is_html = FALSE;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]