aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Winship <danw@src.gnome.org>2002-08-15 21:16:26 +0800
committerDan Winship <danw@src.gnome.org>2002-08-15 21:16:26 +0800
commit419fb428ad227bd3bfc63076c46bc81afd98c3b8 (patch)
tree7b23df6160b849963fa83b517f50910f1bcdff58
parentaa593c3d2f49c51ec03f5f63ecc3c88bd4c9cde3 (diff)
downloadgsoc2013-evolution-419fb428ad227bd3bfc63076c46bc81afd98c3b8.tar.gz
gsoc2013-evolution-419fb428ad227bd3bfc63076c46bc81afd98c3b8.tar.zst
gsoc2013-evolution-419fb428ad227bd3bfc63076c46bc81afd98c3b8.zip
Don't turn on pgp signing if this is an iMIP message and pgp_no_imip_sign
* e-msg-composer.c (from_changed_cb): Don't turn on pgp signing if this is an iMIP message and pgp_no_imip_sign is set. (e_msg_composer_set_body): If setting a text/calendar body and pgp_no_imip_sign is true, turn off signing. svn path=/trunk/; revision=17779
-rw-r--r--composer/ChangeLog7
-rw-r--r--composer/e-msg-composer.c11
2 files changed, 17 insertions, 1 deletions
diff --git a/composer/ChangeLog b/composer/ChangeLog
index 17b9dd2636..059eed96db 100644
--- a/composer/ChangeLog
+++ b/composer/ChangeLog
@@ -1,3 +1,10 @@
+2002-08-14 Dan Winship <danw@ximian.com>
+
+ * e-msg-composer.c (from_changed_cb): Don't turn on pgp signing if
+ this is an iMIP message and pgp_no_imip_sign is set.
+ (e_msg_composer_set_body): If setting a text/calendar body and
+ pgp_no_imip_sign is true, turn off signing.
+
2002-08-13 Jeffrey Stedfast <fejj@ximian.com>
* e-msg-composer.c (do_exit): Make the warning dialog display the
diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c
index 2a6180c21e..5138227383 100644
--- a/composer/e-msg-composer.c
+++ b/composer/e-msg-composer.c
@@ -2329,7 +2329,10 @@ from_changed_cb (EMsgComposerHdrs *hdrs, void *data)
if (hdrs->account) {
const MailConfigAccount *account = hdrs->account;
- e_msg_composer_set_pgp_sign (composer, account->pgp_always_sign);
+ e_msg_composer_set_pgp_sign (composer,
+ account->pgp_always_sign &&
+ (!account->pgp_no_imip_sign || !composer->mime_type ||
+ g_strncasecmp (composer->mime_type, "text/calendar", 13) != 0));
e_msg_composer_set_smime_sign (composer, account->smime_always_sign);
update_auto_recipients (hdrs, UPDATE_AUTO_CC, account->always_cc ? account->cc_addrs : NULL);
update_auto_recipients (hdrs, UPDATE_AUTO_BCC, account->always_bcc ? account->bcc_addrs : NULL);
@@ -3863,6 +3866,12 @@ e_msg_composer_set_body (EMsgComposer *composer, const char *body,
composer->mime_body = g_strdup (body);
g_free (composer->mime_type);
composer->mime_type = g_strdup (mime_type);
+
+ if (g_strncasecmp (composer->mime_type, "text/calendar", 13) == 0) {
+ EMsgComposerHdrs *hdrs = E_MSG_COMPOSER_HDRS (composer->hdrs);
+ if (hdrs->account && hdrs->account->pgp_no_imip_sign)
+ e_msg_composer_set_pgp_sign (composer, FALSE);
+ }
}