removed local account without SMTP server - added option to use mail command
[claws.git] / src / prefs_headers.c
index e7c053ddb15a09b4b2f1ec6742bb68867ce4a4d6..81274242c67b3cfaa01d82c23fabea73d400433b 100644 (file)
@@ -40,7 +40,7 @@
 #include "mainwindow.h"
 #include "foldersel.h"
 #include "manage_window.h"
-#include "headers.h"
+#include "customheader.h"
 #include "utils.h"
 #include "gtkutils.h"
 #include "alertpanel.h"
@@ -89,9 +89,6 @@ static void prefs_headers_select              (GtkCList       *clist,
                                         gint            column,
                                         GdkEvent       *event);
 
-static void prefs_headers_dest_radio_button_toggled    (void);
-static void prefs_headers_notrecv_radio_button_toggled (void);
-
 static void prefs_headers_key_pressed  (GtkWidget      *widget,
                                         GdkEventKey    *event,
                                         gpointer        data);
@@ -339,7 +336,7 @@ void prefs_headers_read_config(PrefsAccount * ac)
                g_strchomp(buf);
                ch = custom_header_read_str(buf);
                if (ch) {
-                       if (strcmp(ch->account_name, ac->account_name) == 0)
+                       if (ch->account_id == ac->account_id)
                                ac->customhdr_list =
                                        g_slist_append(ac->customhdr_list, ch);
                        else
@@ -375,7 +372,7 @@ void prefs_headers_write_config(PrefsAccount * ac)
                        g_strchomp(buf);
                        ch = custom_header_read_str(buf);
                        if (ch) {
-                               if (strcmp(ch->account_name, ac->account_name) != 0)
+                               if (ch->account_id != ac->account_id)
                                        all_hdrs =
                                                g_slist_append(all_hdrs, ch);
                                else
@@ -501,7 +498,7 @@ static gint prefs_headers_clist_set_row(PrefsAccount * ac, gint row)
 
        ch = g_new0(CustomHeader, 1);
 
-       ch->account_name = g_strdup(ac->account_name);
+       ch->account_id = ac->account_id;
 
        ch->name = g_strdup(entry_text);
 
@@ -609,7 +606,7 @@ static void prefs_headers_select(GtkCList *clist, gint row, gint column,
                                GdkEvent *event)
 {
        CustomHeader *ch;
-       CustomHeader default_ch = { "", NULL };
+       CustomHeader default_ch = { 0, "", NULL };
  
        ch = gtk_clist_get_row_data(clist, row);
        if (!ch)