evolution r36779 - in trunk: . mail



Author: mcrha
Date: Wed Nov 12 20:03:07 2008
New Revision: 36779
URL: http://svn.gnome.org/viewvc/evolution?rev=36779&view=rev

Log:
2008-11-12  Milan Crha  <mcrha redhat com>

	** Part of fix for bug #524377

	* configure.in: Bump eds minimum version to 2.25.2 because of
	camel's int camel_header_param_encode_filenames_in_rfc_2047.

	* mail/mail-config.glade:
	* mail/evolution-mail.schemas.in:
	* mail/em-composer-prefs.c: (em_composer_prefs_construct):
	* mail/mail-config.c: (gconf_outlook_filenames_changed), (mail_config_init):
	Declare, be able to change and listen to changes on new key,
	'/apps/evolution/mail/composer/outlook_filenames' to encode file names
	header in camel based on the RFC 2047, instead of the correct RFC 2231.

Note: Requires at least eds revision 9756.


Modified:
   trunk/ChangeLog
   trunk/configure.in
   trunk/mail/ChangeLog
   trunk/mail/em-composer-prefs.c
   trunk/mail/evolution-mail.schemas.in
   trunk/mail/mail-config.c
   trunk/mail/mail-config.glade

Modified: trunk/configure.in
==============================================================================
--- trunk/configure.in	(original)
+++ trunk/configure.in	Wed Nov 12 20:03:07 2008
@@ -23,7 +23,7 @@
 # Required Packages
 m4_define([glib_minimum_version], [2.18.0])
 m4_define([gtk_minimum_version], [2.12.0])
-m4_define([eds_minimum_version], [2.23.91])
+m4_define([eds_minimum_version], [2.25.2])
 m4_define([gnome_icon_theme_minimum_version], [2.19.91])
 m4_define([libbonobo_minimum_version], [2.20.3])
 m4_define([libbonoboui_minimum_version], [2.4.2])

Modified: trunk/mail/em-composer-prefs.c
==============================================================================
--- trunk/mail/em-composer-prefs.c	(original)
+++ trunk/mail/em-composer-prefs.c	Wed Nov 12 20:03:07 2008
@@ -917,6 +917,12 @@
 		gtk_widget_set_sensitive (widget, FALSE);
 	gconf_bridge_bind_property (bridge, key, G_OBJECT (widget), "active");
 
+	key = "/apps/evolution/mail/composer/outlook_filenames";
+	widget = glade_xml_get_widget (gui, "chkOutlookFilenames");
+	if (!gconf_client_key_is_writable (client, key, NULL))
+		gtk_widget_set_sensitive (widget, FALSE);
+	gconf_bridge_bind_property (bridge, key, G_OBJECT (widget), "active");
+
 	key = "/apps/evolution/mail/composer/top_signature";
 	widget = glade_xml_get_widget (gui, "chkTopSignature");
 	if (!gconf_client_key_is_writable (client, key, NULL))

Modified: trunk/mail/evolution-mail.schemas.in
==============================================================================
--- trunk/mail/evolution-mail.schemas.in	(original)
+++ trunk/mail/evolution-mail.schemas.in	Wed Nov 12 20:03:07 2008
@@ -186,6 +186,20 @@
     </schema>
 
     <schema>
+      <key>/schemas/apps/evolution/mail/composer/outlook_filenames</key>
+      <applyto>/apps/evolution/mail/composer/outlook_filenames</applyto>
+      <owner>evolution-mail</owner>
+      <type>bool</type>
+      <default>false</default>
+      <locale name="C">
+         <short>Encode file names in an Outlook/GMail way</short>
+         <long>
+          Encode file names in the mail headers same as Outlook or GMail does, to let them understand localized file names sent by Evolution, because they do not follow the RFC 2231, but uses incorrect RFC 2047 standard.
+         </long>
+      </locale>
+    </schema>
+
+    <schema>
       <key>/schemas/apps/evolution/mail/composer/width</key>
       <applyto>/apps/evolution/mail/composer/width</applyto>
       <owner>evolution-mail</owner>

Modified: trunk/mail/mail-config.c
==============================================================================
--- trunk/mail/mail-config.c	(original)
+++ trunk/mail/mail-config.c	Wed Nov 12 20:03:07 2008
@@ -248,6 +248,22 @@
 }
 
 static void
+gconf_outlook_filenames_changed (GConfClient *client, guint cnxn_id,
+				 GConfEntry *entry, gpointer user_data)
+{
+	extern int camel_header_param_encode_filenames_in_rfc_2047;
+
+	g_return_if_fail (client != NULL);
+
+	/* pass option to the camel */
+	if (gconf_client_get_bool (client, "/apps/evolution/mail/composer/outlook_filenames", NULL)) {
+		camel_header_param_encode_filenames_in_rfc_2047 = 1;
+	} else {
+		camel_header_param_encode_filenames_in_rfc_2047 = 0;
+	}
+}
+
+static void
 gconf_jh_check_changed (GConfClient *client, guint cnxn_id,
 		     GConfEntry *entry, gpointer user_data)
 {
@@ -369,6 +385,12 @@
 	gconf_client_notify_add (
 		config->gconf, key, func, NULL, NULL, NULL);
 
+	key = "/apps/evolution/mail/composer/outlook_filenames";
+	func = (GConfClientNotifyFunc) gconf_outlook_filenames_changed;
+	gconf_outlook_filenames_changed (config->gconf, 0, NULL, NULL);
+	gconf_client_notify_add (
+		config->gconf, key, func, NULL, NULL, NULL);
+
 	/* Display Configuration */
 
 	gconf_client_add_dir (

Modified: trunk/mail/mail-config.glade
==============================================================================
--- trunk/mail/mail-config.glade	(original)
+++ trunk/mail/mail-config.glade	Wed Nov 12 20:03:07 2008
@@ -7124,6 +7124,25 @@
 			  </child>
 
 			  <child>
+			    <widget class="GtkCheckButton" id="chkOutlookFilenames">
+			      <property name="visible">True</property>
+			      <property name="can_focus">True</property>
+			      <property name="label" translatable="yes">Encode file names in an Outlook/GMail way</property>
+			      <property name="use_underline">True</property>
+			      <property name="relief">GTK_RELIEF_NORMAL</property>
+			      <property name="focus_on_click">True</property>
+			      <property name="active">False</property>
+			      <property name="inconsistent">False</property>
+			      <property name="draw_indicator">True</property>
+			    </widget>
+			    <packing>
+			      <property name="padding">0</property>
+			      <property name="expand">False</property>
+			      <property name="fill">False</property>
+			    </packing>
+			  </child>
+
+			  <child>
 			    <widget class="GtkTable" id="tableForwardsReplies">
 			      <property name="visible">True</property>
 			      <property name="n_rows">3</property>



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