#include "main.h"
#include "prefs.h"
#include "prefs_common.h"
+#include "prefs_display_header.h"
#include "mainwindow.h"
#include "summaryview.h"
#include "messageview.h"
#include "manage_window.h"
+#include "inc.h"
#include "menu.h"
#include "codeconv.h"
#include "utils.h"
GtkWidget *chkbtn_folder_unread;
GtkWidget *chkbtn_transhdr;
+
GtkWidget *chkbtn_swapfrom;
GtkWidget *chkbtn_hscrollbar;
- GtkWidget *entry_datefmt;
+ GtkWidget *chkbtn_useaddrbook;
} display;
static struct Message {
#if USE_GPGME
static struct Privacy {
+ GtkWidget *checkbtn_gpgme_warning;
GtkWidget *checkbtn_default_encrypt;
GtkWidget *checkbtn_default_sign;
GtkWidget *checkbtn_auto_check_signatures;
GtkWidget *checkbtn_cleanonexit;
GtkWidget *checkbtn_askonclean;
GtkWidget *checkbtn_warnqueued;
+ GtkWidget *checkbtn_returnreceipt;
GtkWidget *checkbtn_addaddrbyclick;
} interface;
static GtkWidget *font_sel_win;
static GtkWidget *quote_color_win;
static GtkWidget *color_dialog;
+static GtkWidget *entry_datefmt;
+static GtkWidget *datefmt_sample;
static void prefs_common_charset_set_data_from_optmenu(PrefParam *pparam);
static void prefs_common_charset_set_optmenu (PrefParam *pparam);
&display.chkbtn_folder_unread,
prefs_set_data_from_toggle, prefs_set_toggle},
- /* Display: Summary View */
{"translate_header", "TRUE", &prefs_common.trans_hdr, P_BOOL,
&display.chkbtn_transhdr,
prefs_set_data_from_toggle, prefs_set_toggle},
+
+ /* Display: Summary View */
{"enable_swap_from", "TRUE", &prefs_common.swap_from, P_BOOL,
&display.chkbtn_swapfrom,
prefs_set_data_from_toggle, prefs_set_toggle},
{"enable_hscrollbar", "TRUE", &prefs_common.enable_hscrollbar, P_BOOL,
&display.chkbtn_hscrollbar,
prefs_set_data_from_toggle, prefs_set_toggle},
+ {"use_address_book", "TRUE", &prefs_common.use_addr_book, P_BOOL,
+ &display.chkbtn_useaddrbook,
+ prefs_set_data_from_toggle, prefs_set_toggle},
{"date_format", "%y/%m/%d(%a) %H:%M", &prefs_common.date_format,
- P_STRING, &display.entry_datefmt,
+ P_STRING, &entry_datefmt,
prefs_set_data_from_entry, prefs_set_entry},
{"enable_thread", "TRUE", &prefs_common.enable_thread, P_BOOL,
NULL, NULL, NULL},
{"show_number", "TRUE", &prefs_common.show_number, P_BOOL,
NULL, NULL, NULL},
+ {"show_score", "TRUE", &prefs_common.show_score, P_BOOL,
+ NULL, NULL, NULL},
{"show_size", "FALSE", &prefs_common.show_size, P_BOOL,
NULL, NULL, NULL},
{"show_date", "TRUE", &prefs_common.show_date, P_BOOL,
NULL, NULL, NULL},
{"summary_col_number", "40", &prefs_common.summary_col_number, P_INT,
NULL, NULL, NULL},
+ {"summary_col_score", "40", &prefs_common.summary_col_score,
+ P_INT, NULL, NULL, NULL},
{"summary_col_size", "48", &prefs_common.summary_col_size, P_INT,
NULL, NULL, NULL},
{"summary_col_date", "120", &prefs_common.summary_col_date, P_INT,
&message.chkbtn_halfpage,
prefs_set_data_from_toggle, prefs_set_toggle},
+ {"show_other_header", "FALSE", &prefs_common.show_other_header, P_BOOL,
+ NULL, NULL, NULL},
+
/* MIME viewer */
{"mime_image_viewer", "display '%s'",
&prefs_common.mime_image_viewer, P_STRING, NULL, NULL, NULL},
#if USE_GPGME
/* Privacy */
+ {"gpgme_warning", "TRUE", &prefs_common.gpgme_warning, P_BOOL,
+ &privacy.checkbtn_gpgme_warning,
+ prefs_set_data_from_toggle, prefs_set_toggle},
{"default_encrypt", "FALSE", &prefs_common.default_encrypt, P_BOOL,
&privacy.checkbtn_default_encrypt,
prefs_set_data_from_toggle, prefs_set_toggle},
&prefs_common.auto_check_signatures, P_BOOL,
&privacy.checkbtn_auto_check_signatures,
prefs_set_data_from_toggle, prefs_set_toggle},
+#ifndef __MINGW32__
{"passphrase_grab", "FALSE", &prefs_common.passphrase_grab, P_BOOL,
&privacy.checkbtn_passphrase_grab,
prefs_set_data_from_toggle, prefs_set_toggle},
+#endif /* __MINGW32__ */
{"default_signkey", CS_AUTO, &prefs_common.default_signkey, P_STRING,
&privacy.optmenu_default_signkey,
prefs_common_default_signkey_set_data_from_optmenu,
{"confirm_on_exit", "TRUE", &prefs_common.confirm_on_exit, P_BOOL,
&interface.checkbtn_confonexit,
prefs_set_data_from_toggle, prefs_set_toggle},
+ {"send_return_receipt", "TRUE", &prefs_common.return_receipt, P_BOOL,
+ &interface.checkbtn_returnreceipt,
+ prefs_set_data_from_toggle, prefs_set_toggle},
{"clean_trash_on_exit", "FALSE", &prefs_common.clean_on_exit, P_BOOL,
&interface.checkbtn_cleanonexit,
prefs_set_data_from_toggle, prefs_set_toggle},
static void prefs_common_key_pressed (GtkWidget *widget,
GdkEventKey *event,
gpointer data);
-static void prefs_common_ok (GtkButton *button);
-static void prefs_common_apply (GtkButton *button);
+static void prefs_common_ok (void);
+static void prefs_common_apply (void);
+static void prefs_common_cancel (void);
void prefs_common_read_config(void)
{
void prefs_common_open(void)
{
+ inc_autocheck_timer_remove();
+
if (!dialog.window) {
prefs_common_create();
}
gtk_window_set_title (GTK_WINDOW(dialog.window),
_("Common Preferences"));
gtk_signal_connect (GTK_OBJECT(dialog.window), "delete_event",
- GTK_SIGNAL_FUNC(gtk_widget_hide_on_delete), NULL);
+ GTK_SIGNAL_FUNC(prefs_common_cancel), NULL);
gtk_signal_connect (GTK_OBJECT(dialog.window), "key_press_event",
GTK_SIGNAL_FUNC(prefs_common_key_pressed), NULL);
gtk_signal_connect (GTK_OBJECT(dialog.window), "focus_in_event",
gtk_signal_connect (GTK_OBJECT(dialog.apply_btn), "clicked",
GTK_SIGNAL_FUNC(prefs_common_apply), NULL);
gtk_signal_connect_object (GTK_OBJECT(dialog.cancel_btn), "clicked",
- GTK_SIGNAL_FUNC(gtk_widget_hide_on_delete),
+ GTK_SIGNAL_FUNC(prefs_common_cancel),
GTK_OBJECT(dialog.window));
/* create all widgets on notebook */
gtk_widget_show (hbox_autochk);
gtk_box_pack_start (GTK_BOX (vbox2), hbox_autochk, FALSE, FALSE, 0);
- gtk_widget_set_sensitive(hbox_autochk, FALSE);
-
PACK_CHECK_BUTTON (hbox_autochk, checkbtn_autochk,
_("Auto-check new mail"));
compose.checkbtn_wrapatsend = checkbtn_wrapatsend;
}
+
+/* alfons - nice ui for darko */
+
+static void date_format_close_btn_clicked(GtkButton *button, GtkWidget **widget)
+{
+ gchar *text;
+
+ g_return_if_fail(widget != NULL);
+ g_return_if_fail(*widget != NULL);
+ g_return_if_fail(entry_datefmt != NULL);
+ g_return_if_fail(datefmt_sample != NULL);
+
+ text = gtk_editable_get_chars(GTK_EDITABLE(datefmt_sample), 0, -1);
+ g_free(prefs_common.date_format);
+ prefs_common.date_format = text;
+ gtk_entry_set_text(GTK_ENTRY(entry_datefmt), text);
+
+ gtk_widget_destroy(*widget);
+ *widget = NULL;
+}
+
+static gboolean date_format_on_delete(GtkWidget *dialogwidget, gpointer d1, GtkWidget **widget)
+{
+ g_return_if_fail(widget != NULL);
+ g_return_if_fail(*widget != NULL);
+ *widget = NULL;
+ return FALSE;
+}
+
+static void date_format_entry_on_change(GtkEditable *editable, GtkLabel *example)
+{
+ time_t cur_time;
+ struct tm *cal_time;
+ char buffer[100];
+ char *text;
+ cur_time = time(NULL);
+ cal_time = localtime(&cur_time);
+ buffer[0] = 0;
+ text = gtk_editable_get_chars(editable, 0, -1);
+ if (text) {
+ strftime(buffer, sizeof buffer, text, cal_time);
+ }
+ gtk_label_set_text(example, buffer);
+}
+
+static GtkWidget *create_date_format(GtkButton *button, void *data)
+{
+ static GtkWidget *date_format = NULL;
+ GtkWidget *vbox1;
+ GtkWidget *scrolledwindow1;
+ GtkWidget *date_format_list;
+ GtkWidget *label3;
+ GtkWidget *label4;
+ GtkWidget *table2;
+ GtkWidget *vbox2;
+ GtkWidget *vbox3;
+ GtkWidget *hbox2;
+ GtkWidget *label5;
+ GtkWidget *hbox1;
+ GtkWidget *label6;
+ GtkWidget *label7;
+ GtkWidget *hbox3;
+ GtkWidget *button1;
+
+ const struct {
+ gchar *fmt;
+ gchar *txt;
+ } time_format[] = {
+ { "%a", _("the full abbreviated weekday name") },
+ { "%A", _("the full weekday name") },
+ { "%b", _("the abbreviated month name") },
+ { "%B", _("the full month name") },
+ { "%c", _("the preferred date and time for the current locale") },
+ { "%C", _("the century number (year/100)") },
+ { "%d", _("the day of the month as a decimal number") },
+ { "%H", _("the hour as a decimal number using a 24-hour clock") },
+ { "%I", _("the hour as a decimal number using a 12-hour clock") },
+ { "%j", _("the day of the year as a decimal number") },
+ { "%m", _("the month as a decimal number") },
+ { "%M", _("the minute as a decimal number") },
+ { "%p", _("either AM or PM") },
+ { "%S", _("the second as a decimal number") },
+ { "%w", _("the day of the week as a decimal number") },
+ { "%x", _("the preferred date for the current locale") },
+ { "%y", _("the last two digits of a year") },
+ { "%Y", _("the year as a decimal number") },
+ { "%Z", _("the time zone or name or abbreviation") }
+ };
+ int tmp;
+ const int TIME_FORMAT_ELEMS = sizeof time_format / sizeof time_format[0];
+
+ if (date_format) return date_format;
+
+ date_format = gtk_window_new(GTK_WINDOW_DIALOG);
+ gtk_window_set_title(GTK_WINDOW(date_format), _("Date format"));
+ gtk_window_set_position(GTK_WINDOW(date_format), GTK_WIN_POS_CENTER);
+ gtk_window_set_default_size(GTK_WINDOW(date_format), 440, 200);
+
+ vbox1 = gtk_vbox_new(FALSE, 10);
+ gtk_widget_show(vbox1);
+ gtk_container_add(GTK_CONTAINER(date_format), vbox1);
+
+ scrolledwindow1 = gtk_scrolled_window_new(NULL, NULL);
+ gtk_widget_show(scrolledwindow1);
+ gtk_box_pack_start(GTK_BOX(vbox1), scrolledwindow1, TRUE, TRUE, 0);
+
+ date_format_list = gtk_clist_new(2);
+ gtk_widget_show(date_format_list);
+ gtk_container_add(GTK_CONTAINER(scrolledwindow1), date_format_list);
+ gtk_clist_set_column_width(GTK_CLIST(date_format_list), 0, 80);
+ gtk_clist_set_column_width(GTK_CLIST(date_format_list), 1, 80);
+ gtk_clist_column_titles_show(GTK_CLIST(date_format_list));
+
+ label3 = gtk_label_new(_("Date Format"));
+ gtk_widget_show(label3);
+ gtk_clist_set_column_widget(GTK_CLIST(date_format_list), 0, label3);
+
+ label4 = gtk_label_new(_("Date Format Description"));
+ gtk_widget_show(label4);
+ gtk_clist_set_column_widget(GTK_CLIST(date_format_list), 1, label4);
+
+ for (tmp = 0; tmp < TIME_FORMAT_ELEMS; tmp++) {
+ gchar *text[3];
+ /* phoney casting necessary because of gtk... */
+ text[0] = (gchar *) time_format[tmp].fmt;
+ text[1] = (gchar *) time_format[tmp].txt;
+ text[2] = NULL;
+ gtk_clist_append(GTK_CLIST(date_format_list), text);
+ }
+
+ table2 = gtk_table_new(1, 1, TRUE);
+ gtk_widget_show(table2);
+ gtk_box_pack_start(GTK_BOX(vbox1), table2, FALSE, TRUE, 0);
+
+ vbox2 = gtk_vbox_new(FALSE, 0);
+ gtk_widget_show(vbox2);
+ gtk_table_attach(GTK_TABLE(table2), vbox2, 0, 1, 0, 1,
+ (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
+ (GtkAttachOptions) (GTK_EXPAND | GTK_FILL), 0, 0);
+
+ vbox3 = gtk_vbox_new(TRUE, 4);
+ gtk_widget_show(vbox3);
+ gtk_box_pack_end(GTK_BOX(vbox2), vbox3, FALSE, FALSE, 10);
+
+ hbox2 = gtk_hbox_new(FALSE, 0);
+ gtk_widget_show(hbox2);
+ gtk_box_pack_start(GTK_BOX(vbox3), hbox2, TRUE, TRUE, 0);
+
+ label5 = gtk_label_new(_("Date format"));
+ gtk_widget_show(label5);
+ gtk_box_pack_start(GTK_BOX(hbox2), label5, FALSE, FALSE, 0);
+ gtk_misc_set_padding(GTK_MISC(label5), 8, 0);
+
+ datefmt_sample = gtk_entry_new_with_max_length(300);
+ gtk_widget_show(datefmt_sample);
+ gtk_box_pack_start(GTK_BOX(hbox2), datefmt_sample, TRUE, TRUE, 40);
+
+ hbox1 = gtk_hbox_new(FALSE, 0);
+ gtk_widget_show(hbox1);
+ gtk_box_pack_start(GTK_BOX(vbox3), hbox1, TRUE, TRUE, 0);
+
+ label6 = gtk_label_new(_("Example"));
+ gtk_widget_show(label6);
+ gtk_box_pack_start(GTK_BOX(hbox1), label6, FALSE, TRUE, 0);
+ gtk_misc_set_padding(GTK_MISC(label6), 8, 0);
+
+ label7 = gtk_label_new(_("label7"));
+ gtk_widget_show(label7);
+ gtk_box_pack_start(GTK_BOX(hbox1), label7, TRUE, TRUE, 60);
+ gtk_label_set_justify(GTK_LABEL(label7), GTK_JUSTIFY_LEFT);
+
+ hbox3 = gtk_hbox_new(TRUE, 0);
+ gtk_widget_show(hbox3);
+ gtk_box_pack_end(GTK_BOX(vbox3), hbox3, FALSE, FALSE, 0);
+
+ button1 = gtk_button_new_with_label(_("Close"));
+ gtk_widget_show(button1);
+ gtk_box_pack_start(GTK_BOX(hbox3), button1, FALSE, TRUE, 144);
+
+ /* set the current format */
+ gtk_entry_set_text(GTK_ENTRY(datefmt_sample), prefs_common.date_format);
+ date_format_entry_on_change(GTK_EDITABLE(datefmt_sample),
+ GTK_LABEL(label7));
+
+ gtk_signal_connect(GTK_OBJECT(button1), "clicked",
+ GTK_SIGNAL_FUNC(date_format_close_btn_clicked), &date_format);
+
+ gtk_signal_connect(GTK_OBJECT(date_format), "delete_event",
+ GTK_SIGNAL_FUNC(date_format_on_delete), &date_format);
+
+ gtk_signal_connect(GTK_OBJECT(datefmt_sample), "changed",
+ GTK_SIGNAL_FUNC(date_format_entry_on_change), label7);
+
+ gtk_window_set_position(GTK_WINDOW(date_format), GTK_WIN_POS_CENTER);
+ gtk_window_set_modal(GTK_WINDOW(date_format), TRUE);
+
+ gtk_widget_show(date_format);
+ return date_format;
+}
+
static void prefs_display_create(void)
{
GtkWidget *vbox1;
GtkWidget *vbox2;
GtkWidget *chkbtn_swapfrom;
GtkWidget *chkbtn_hscrollbar;
+ GtkWidget *chkbtn_useaddrbook;
GtkWidget *hbox1;
GtkWidget *label_datefmt;
- GtkWidget *entry_datefmt;
- GtkTooltips *tooltips_datefmt;
GtkWidget *button_dispitem;
vbox1 = gtk_vbox_new (FALSE, VSPACING);
PACK_CHECK_BUTTON
(vbox2, chkbtn_swapfrom,
_("Display recipient on `From' column if sender is yourself"));
+ PACK_CHECK_BUTTON
+ (vbox2, chkbtn_useaddrbook,
+ _("Display sender using address book"));
PACK_CHECK_BUTTON
(vbox2, chkbtn_hscrollbar, _("Enable horizontal scroll bar"));
- label_datefmt = gtk_label_new (_("Date format"));
+ hbox1 = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox1);
+ gtk_box_pack_start (GTK_BOX (vbox2), hbox1, FALSE, TRUE, 0);
+
+ label_datefmt = gtk_button_new_with_label (_("Date format"));
gtk_widget_show (label_datefmt);
gtk_box_pack_start (GTK_BOX (hbox1), label_datefmt, FALSE, FALSE, 0);
+ gtk_signal_connect(GTK_OBJECT(label_datefmt), "clicked",
+ GTK_SIGNAL_FUNC(create_date_format), NULL);
entry_datefmt = gtk_entry_new ();
gtk_widget_show (entry_datefmt);
gtk_box_pack_start (GTK_BOX (hbox1), entry_datefmt, TRUE, TRUE, 0);
-
- tooltips_datefmt = gtk_tooltips_new ();
- gtk_tooltips_set_tip
- (tooltips_datefmt, entry_datefmt,
- _("Ordinary characters placed in the format string are copied "
- "without conversion. Conversion specifiers are introduced by "
- "a % character, and are replaced as follows:\n"
- "%a: the abbreviated weekday name\n"
- "%A: the full weekday name\n"
- "%b: the abbreviated month name\n"
- "%B: the full month name\n"
- "%c: the preferred date and time for the current locale\n"
- "%C: the century number (year/100)\n"
- "%d: the day of the month as a decimal number\n"
- "%H: the hour as a decimal number using a 24-hour clock\n"
- "%I: the hour as a decimal number using a 12-hour clock\n"
- "%j: the day of the year as a decimal number\n"
- "%m: the month as a decimal number\n"
- "%M: the minute as a decimal number\n"
- "%p: either AM or PM\n"
- "%S: the second as a decimal number\n"
- "%w: the day of the week as a decimal number\n"
- "%x: the preferred date for the current locale\n"
- "%y: the last two digits of a year\n"
- "%Y: the year as a decimal number\n"
- "%Z: the time zone or name or abbreviation"),
- NULL);
-
+
hbox1 = gtk_hbox_new (FALSE, 8);
gtk_widget_show (hbox1);
gtk_box_pack_start (GTK_BOX (vbox2), hbox1, FALSE, TRUE, 0);
display.button_textfont = button_textfont;
display.chkbtn_folder_unread = chkbtn_folder_unread;
-
display.chkbtn_transhdr = chkbtn_transhdr;
- display.chkbtn_swapfrom = chkbtn_swapfrom;
- display.chkbtn_hscrollbar = chkbtn_hscrollbar;
- display.entry_datefmt = entry_datefmt;
+
+ display.chkbtn_swapfrom = chkbtn_swapfrom;
+ display.chkbtn_hscrollbar = chkbtn_hscrollbar;
+ display.chkbtn_useaddrbook = chkbtn_useaddrbook;
}
static void prefs_message_create(void)
GtkWidget *chkbtn_mbalnum;
GtkWidget *chkbtn_disphdrpane;
GtkWidget *chkbtn_disphdr;
+ GtkWidget *button_edit_disphdr;
GtkWidget *hbox_linespc;
GtkWidget *label_linespc;
GtkObject *spinbtn_linespc_adj;
_("Display 2-byte alphabet and numeric with 1-byte character"));
PACK_CHECK_BUTTON(vbox2, chkbtn_disphdrpane,
_("Display header pane above message view"));
- PACK_CHECK_BUTTON(vbox2, chkbtn_disphdr,
- _("Display short headers on message view"));
+
+ hbox1 = gtk_hbox_new (FALSE, 8);
+ gtk_widget_show (hbox1);
+ gtk_box_pack_start (GTK_BOX (vbox2), hbox1, FALSE, TRUE, 0);
+
+ PACK_CHECK_BUTTON(hbox1, chkbtn_disphdr,
+ _("Display short headers on message view"));
+
+ button_edit_disphdr = gtk_button_new_with_label (_(" Edit... "));
+ gtk_widget_show (button_edit_disphdr);
+ gtk_box_pack_end (GTK_BOX (hbox1), button_edit_disphdr,
+ FALSE, TRUE, 0);
+ gtk_signal_connect (GTK_OBJECT (button_edit_disphdr), "clicked",
+ GTK_SIGNAL_FUNC (prefs_display_header_open),
+ NULL);
+
+ SET_TOGGLE_SENSITIVITY(chkbtn_disphdr, button_edit_disphdr);
hbox1 = gtk_hbox_new (FALSE, 32);
gtk_widget_show (hbox1);
GtkWidget *vbox1;
GtkWidget *vbox2;
GtkWidget *hbox1;
+ GtkWidget *checkbtn_gpgme_warning;
GtkWidget *checkbtn_default_encrypt;
GtkWidget *checkbtn_default_sign;
GtkWidget *checkbtn_auto_check_signatures;
gtk_widget_show (vbox2);
gtk_box_pack_start (GTK_BOX (vbox1), vbox2, FALSE, FALSE, 0);
+ PACK_CHECK_BUTTON
+ (vbox2, checkbtn_gpgme_warning,
+ _("Display warning on startup if GnuPG does not work"));
+
PACK_CHECK_BUTTON (vbox2, checkbtn_default_encrypt,
_("Encrypt message by default"));
PACK_CHECK_BUTTON (vbox2, checkbtn_auto_check_signatures,
_("Automatically check signatures"));
+#ifndef __MINGW32__
PACK_CHECK_BUTTON (vbox2, checkbtn_passphrase_grab,
_("Grab input while entering a passphrase"));
+#endif
hbox1 = gtk_hbox_new (FALSE, 8);
gtk_widget_show (hbox1);
/* FIXME: disabled because not implemented */
gtk_widget_set_sensitive(optmenu, FALSE);
+ privacy.checkbtn_gpgme_warning = checkbtn_gpgme_warning;
privacy.checkbtn_default_encrypt = checkbtn_default_encrypt;
privacy.checkbtn_default_sign = checkbtn_default_sign;
privacy.checkbtn_auto_check_signatures
GtkWidget *checkbtn_cleanonexit;
GtkWidget *checkbtn_askonclean;
GtkWidget *checkbtn_warnqueued;
+ GtkWidget *checkbtn_returnreceipt;
vbox1 = gtk_vbox_new (FALSE, VSPACING);
gtk_widget_show (vbox1);
SET_TOGGLE_SENSITIVITY (checkbtn_cleanonexit, checkbtn_askonclean);
PACK_CHECK_BUTTON (vbox_exit, checkbtn_warnqueued,
- _("Warn if there are queued messages on exit"));
+ _("Warn if there are queued messages"));
+
+ PACK_CHECK_BUTTON (vbox_exit, checkbtn_returnreceipt,
+ _("Send return receipt on request"));
interface.checkbtn_emacs = checkbtn_emacs;
interface.checkbtn_openunread = checkbtn_openunread;
interface.checkbtn_cleanonexit = checkbtn_cleanonexit;
interface.checkbtn_askonclean = checkbtn_askonclean;
interface.checkbtn_warnqueued = checkbtn_warnqueued;
+ interface.checkbtn_returnreceipt = checkbtn_returnreceipt;
}
static void prefs_other_create(void)
gtk_widget_hide(quote_color_win);
textview_update_message_colors();
+ main_window_reflect_prefs_all();
}
static void prefs_quote_colors_dialog_create(void)
SET_ACTIVE(S_COL_UNREAD, show_unread);
SET_ACTIVE(S_COL_MIME, show_mime);
SET_ACTIVE(S_COL_NUMBER, show_number);
+ SET_ACTIVE(S_COL_SCORE, show_score);
SET_ACTIVE(S_COL_SIZE, show_size);
SET_ACTIVE(S_COL_DATE, show_date);
SET_ACTIVE(S_COL_FROM, show_from);
GET_ACTIVE(S_COL_UNREAD, show_unread);
GET_ACTIVE(S_COL_MIME, show_mime);
GET_ACTIVE(S_COL_NUMBER, show_number);
+ GET_ACTIVE(S_COL_SCORE, show_score);
GET_ACTIVE(S_COL_SIZE, show_size);
GET_ACTIVE(S_COL_DATE, show_date);
GET_ACTIVE(S_COL_FROM, show_from);
SET_CHECK_BUTTON(S_COL_UNREAD, _("Unread"));
SET_CHECK_BUTTON(S_COL_MIME, _("MIME"));
SET_CHECK_BUTTON(S_COL_NUMBER, _("Number"));
+ SET_CHECK_BUTTON(S_COL_SCORE, _("Score"));
SET_CHECK_BUTTON(S_COL_SIZE, _("Size"));
SET_CHECK_BUTTON(S_COL_DATE, _("Date"));
SET_CHECK_BUTTON(S_COL_FROM, _("From"));
gpointer data)
{
if (event && event->keyval == GDK_Escape)
- gtk_widget_hide(dialog.window);
+ prefs_common_cancel();
}
-static void prefs_common_ok(GtkButton *button)
+static void prefs_common_ok(void)
{
- prefs_common_apply(button);
+ prefs_common_apply();
gtk_widget_hide(dialog.window);
if (quote_desc_win && GTK_WIDGET_VISIBLE(quote_desc_win))
gtk_widget_hide(quote_desc_win);
+
+ inc_autocheck_timer_set();
}
-static void prefs_common_apply(GtkButton *button)
+static void prefs_common_apply(void)
{
prefs_set_data_from_dialog(param);
main_window_reflect_prefs_all();
prefs_common_save_config();
}
+
+static void prefs_common_cancel(void)
+{
+ gtk_widget_hide(dialog.window);
+ inc_autocheck_timer_set();
+}