aboutsummaryrefslogtreecommitdiffstats
path: root/mail/mail-config.c
diff options
context:
space:
mode:
authorRadek Doulik <rodo@ximian.com>2001-06-29 00:23:55 +0800
committerRadek Doulik <rodo@src.gnome.org>2001-06-29 00:23:55 +0800
commit311491b26baf67164d5486b13cf794c29d6000cf (patch)
tree2de6ed152ea1446ff801a731e854e715cdcc4533 /mail/mail-config.c
parent3460368f5986462c91b18f1a7c9ffac67031f9cd (diff)
downloadgsoc2013-evolution-311491b26baf67164d5486b13cf794c29d6000cf.tar
gsoc2013-evolution-311491b26baf67164d5486b13cf794c29d6000cf.tar.gz
gsoc2013-evolution-311491b26baf67164d5486b13cf794c29d6000cf.tar.bz2
gsoc2013-evolution-311491b26baf67164d5486b13cf794c29d6000cf.tar.lz
gsoc2013-evolution-311491b26baf67164d5486b13cf794c29d6000cf.tar.xz
gsoc2013-evolution-311491b26baf67164d5486b13cf794c29d6000cf.tar.zst
gsoc2013-evolution-311491b26baf67164d5486b13cf794c29d6000cf.zip
simplified(refactored) signature handling + better support for html
signatures 2001-06-28 Radek Doulik <rodo@ximian.com> * mail-config.c: use new fields everywhere * mail-config.h: as below * Mail.idl: added html_signature and has_html_signature svn path=/trunk/; revision=10564
Diffstat (limited to 'mail/mail-config.c')
-rw-r--r--mail/mail-config.c21
1 files changed, 19 insertions, 2 deletions
diff --git a/mail/mail-config.c b/mail/mail-config.c
index 183c31436a..0672b81d6d 100644
--- a/mail/mail-config.c
+++ b/mail/mail-config.c
@@ -97,7 +97,9 @@ identity_copy (const MailConfigIdentity *id)
new->address = g_strdup (id->address);
new->organization = g_strdup (id->organization);
new->signature = g_strdup (id->signature);
-
+ new->html_signature = g_strdup (id->html_signature);
+ new->has_html_signature = id->has_html_signature;
+
return new;
}
@@ -111,6 +113,7 @@ identity_destroy (MailConfigIdentity *id)
g_free (id->address);
g_free (id->organization);
g_free (id->signature);
+ g_free (id->html_signature);
g_free (id);
}
@@ -349,7 +352,13 @@ config_read (void)
path = g_strdup_printf ("identity_signature_%d", i);
id->signature = gnome_config_get_string (path);
g_free (path);
-
+ path = g_strdup_printf ("identity_html_signature_%d", i);
+ id->html_signature = gnome_config_get_string (path);
+ g_free (path);
+ path = g_strdup_printf ("identity_has_html_signature_%d", i);
+ id->has_html_signature = gnome_config_get_bool_with_default (path, FALSE);
+ g_free (path);
+
/* get the source */
source = g_new0 (MailConfigService, 1);
path = g_strdup_printf ("source_url_%d", i);
@@ -618,6 +627,12 @@ mail_config_write (void)
path = g_strdup_printf ("identity_signature_%d", i);
gnome_config_set_string (path, account->id->signature);
g_free (path);
+ path = g_strdup_printf ("identity_html_signature_%d", i);
+ gnome_config_set_string (path, account->id->html_signature);
+ g_free (path);
+ path = g_strdup_printf ("identity_has_html_signature_%d", i);
+ gnome_config_set_bool (path, account->id->has_html_signature);
+ g_free (path);
/* source info */
path = g_strdup_printf ("source_url_%d", i);
@@ -1517,6 +1532,8 @@ impl_GNOME_Evolution_MailConfig_addAccount (PortableServer_Servant servant,
mail_id->address = g_strdup (id.address);
mail_id->organization = g_strdup (id.organization);
mail_id->signature = g_strdup (id.signature);
+ mail_id->html_signature = g_strdup (id.html_signature);
+ mail_id->has_html_signature = id.has_html_signature;
mail_account->id = mail_id;