aboutsummaryrefslogtreecommitdiffstats
path: root/mail/mail-config.c
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2003-01-09 04:34:53 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2003-01-09 04:34:53 +0800
commit5c49bda7d167c71419950f0dc081a5b8ec56ee68 (patch)
tree079448c5aa4e91b39e43db079a672c712f9d8e0f /mail/mail-config.c
parentac80365c860bc263b183a76a5f035779b60f100f (diff)
downloadgsoc2013-evolution-5c49bda7d167c71419950f0dc081a5b8ec56ee68.tar
gsoc2013-evolution-5c49bda7d167c71419950f0dc081a5b8ec56ee68.tar.gz
gsoc2013-evolution-5c49bda7d167c71419950f0dc081a5b8ec56ee68.tar.bz2
gsoc2013-evolution-5c49bda7d167c71419950f0dc081a5b8ec56ee68.tar.lz
gsoc2013-evolution-5c49bda7d167c71419950f0dc081a5b8ec56ee68.tar.xz
gsoc2013-evolution-5c49bda7d167c71419950f0dc081a5b8ec56ee68.tar.zst
gsoc2013-evolution-5c49bda7d167c71419950f0dc081a5b8ec56ee68.zip
Removed. (mail_config_set_show_preview): Removed.
2003-01-08 Jeffrey Stedfast <fejj@ximian.com> * mail-config.c (mail_config_get_show_preview): Removed. (mail_config_set_show_preview): Removed. * folder-browser.c (folder_browser_toggle_preview): Simply set the gconf show_preview setting and let the code in folder-browser-ui.c detect it and update the UI. * folder-browser-ui.c (folder_browser_ui_add_global): Listen for changed events on the show_preview setting. svn path=/trunk/; revision=19288
Diffstat (limited to 'mail/mail-config.c')
-rw-r--r--mail/mail-config.c75
1 files changed, 1 insertions, 74 deletions
diff --git a/mail/mail-config.c b/mail/mail-config.c
index 1c1783b8bd..78bea6fd29 100644
--- a/mail/mail-config.c
+++ b/mail/mail-config.c
@@ -80,7 +80,6 @@ typedef struct {
GSList *accounts;
GHashTable *threaded_hash;
- GHashTable *preview_hash;
GList *signature_list;
int signatures;
@@ -845,10 +844,6 @@ mail_config_write_on_exit (void)
if (config->threaded_hash)
g_hash_table_foreach_remove (config->threaded_hash, hash_save_state, "Threads");
- /* Message Preview */
- if (config->preview_hash)
- g_hash_table_foreach_remove (config->preview_hash, hash_save_state, "Preview");
-
/* Passwords */
/* then we make sure the ones we want to remember are in the
@@ -921,65 +916,6 @@ uri_to_key (const char *uri)
}
gboolean
-mail_config_get_show_preview (const char *uri)
-{
-#warning "FIXME: need to rework how we save state, probably shouldn't use gconf"
-#if 0
- if (uri && *uri) {
- gpointer key, val;
- char *dbkey;
-
- dbkey = uri_to_key (uri);
-
- if (!config->preview_hash)
- config->preview_hash = g_hash_table_new (g_str_hash, g_str_equal);
-
- if (!g_hash_table_lookup_extended (config->preview_hash, dbkey, &key, &val)) {
- gboolean value;
- char *str;
-
- str = g_strdup_printf ("/apps/Evolution/Mail/Preview/%s", dbkey);
- value = e_config_listener_get_boolean_with_default (config->db, str, TRUE, NULL);
- g_free (str);
-
- g_hash_table_insert (config->preview_hash, dbkey,
- GINT_TO_POINTER (value));
-
- return value;
- } else {
- g_free (dbkey);
- return GPOINTER_TO_INT (val);
- }
- }
-#endif
-
- /* return the default value */
-
- return gconf_client_get_bool (config->gconf, "/apps/evolution/mail/display/show_preview", NULL);
-}
-
-void
-mail_config_set_show_preview (const char *uri, gboolean value)
-{
- if (uri && *uri) {
- char *dbkey = uri_to_key (uri);
- gpointer key, val;
-
- if (!config->preview_hash)
- config->preview_hash = g_hash_table_new (g_str_hash, g_str_equal);
-
- if (g_hash_table_lookup_extended (config->preview_hash, dbkey, &key, &val)) {
- g_hash_table_insert (config->preview_hash, dbkey,
- GINT_TO_POINTER (value));
- g_free (dbkey);
- } else {
- g_hash_table_insert (config->preview_hash, dbkey,
- GINT_TO_POINTER (value));
- }
- }
-}
-
-gboolean
mail_config_get_thread_list (const char *uri)
{
#warning "FIXME: need to rework how we save state, probably shouldn't use gconf"
@@ -1389,16 +1325,7 @@ mail_config_uri_renamed(GCompareFunc uri_cmp, const char *old, const char *new)
g_hash_table_insert (config->threaded_hash, g_strdup(newkey), val);
work = 2;
}
-
- /* ditto */
- mail_config_get_show_preview (old);
- if (g_hash_table_lookup_extended (config->preview_hash, oldkey, &hashkey, &val)) {
- /*printf ("changing key in preview_hash\n");*/
- g_hash_table_remove (config->preview_hash, hashkey);
- g_hash_table_insert (config->preview_hash, g_strdup(newkey), val);
- work = 2;
- }
-
+
g_free (oldkey);
g_free (newkey);