diff options
author | Radek Doulik <rodo@ximian.com> | 2004-01-24 01:21:50 +0800 |
---|---|---|
committer | Radek Doulik <rodo@src.gnome.org> | 2004-01-24 01:21:50 +0800 |
commit | c6ba8e9f2d7c34b91e965343c9356d7e2a80e1a7 (patch) | |
tree | 2758ec5aa34baad0ef195e298dabe3d5414ccb18 /mail/em-mailer-prefs.c | |
parent | 11d2ccf165bbe36403fa59e71725a12ec8614d61 (diff) | |
download | gsoc2013-evolution-c6ba8e9f2d7c34b91e965343c9356d7e2a80e1a7.tar.gz gsoc2013-evolution-c6ba8e9f2d7c34b91e965343c9356d7e2a80e1a7.tar.zst gsoc2013-evolution-c6ba8e9f2d7c34b91e965343c9356d7e2a80e1a7.zip |
use mail_session_get_sa_daemon_port
2004-01-23 Radek Doulik <rodo@ximian.com>
* em-junk-filter.c: use mail_session_get_sa_daemon_port
* em-mailer-prefs.c (em_mailer_prefs_construct): added
check_incoming_imap
(em_mailer_prefs_apply): ditto
(settings_changed): set check_incoming_imap sensitivity by
check_incoming state
* mail-session.c: add sa_daemon_port
(mail_session_init): init sa_daemon_port and check_junk_for_imap
(mail_session_check_junk_notify): watch for sa_daemon_port and
check_junk_for_imap
(mail_session_get_sa_daemon_port): new wrapper
(mail_session_set_sa_daemon_port): ditto
svn path=/trunk/; revision=24382
Diffstat (limited to 'mail/em-mailer-prefs.c')
-rw-r--r-- | mail/em-mailer-prefs.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/mail/em-mailer-prefs.c b/mail/em-mailer-prefs.c index d5a80beef3..946baec956 100644 --- a/mail/em-mailer-prefs.c +++ b/mail/em-mailer-prefs.c @@ -160,6 +160,7 @@ settings_changed (GtkWidget *widget, gpointer user_data) { EMMailerPrefs *prefs = (EMMailerPrefs *) user_data; + gtk_widget_set_sensitive (GTK_WIDGET (prefs->check_incoming_imap), gtk_toggle_button_get_active (prefs->check_incoming)); if (prefs->control) evolution_config_control_changed (prefs->control); } @@ -397,7 +398,7 @@ em_mailer_prefs_construct (EMMailerPrefs *prefs) GtkTreeIter iter; char *font, *buf; GladeXML *gui; - gboolean bool; + gboolean bool, check_incoming; int val, i; gui = glade_xml_new (EVOLUTION_GLADEDIR "/mail-config.glade", "preferences_tab", NULL); @@ -649,10 +650,16 @@ em_mailer_prefs_construct (EMMailerPrefs *prefs) /* Junk prefs */ prefs->check_incoming = GTK_TOGGLE_BUTTON (glade_xml_get_widget (gui, "chkCheckIncomingMail")); - bool = gconf_client_get_bool (prefs->gconf, "/apps/evolution/mail/junk/check_incoming", NULL); + check_incoming = bool = gconf_client_get_bool (prefs->gconf, "/apps/evolution/mail/junk/check_incoming", NULL); gtk_toggle_button_set_active (prefs->check_incoming, bool); g_signal_connect (prefs->check_incoming, "toggled", G_CALLBACK (settings_changed), prefs); + prefs->check_incoming_imap = GTK_TOGGLE_BUTTON (glade_xml_get_widget (gui, "chkDoNotCheckIMAP")); + gtk_widget_set_sensitive (GTK_WIDGET (prefs->check_incoming_imap), check_incoming); + bool = gconf_client_get_bool (prefs->gconf, "/apps/evolution/mail/junk/check_incoming_imap", NULL); + gtk_toggle_button_set_active (prefs->check_incoming_imap, !bool); + g_signal_connect (prefs->check_incoming_imap, "toggled", G_CALLBACK (settings_changed), prefs); + prefs->sa_local_tests_only = GTK_TOGGLE_BUTTON (glade_xml_get_widget (gui, "chkSALocalTestsOnly")); bool = gconf_client_get_bool (prefs->gconf, "/apps/evolution/mail/junk/sa/local_only", NULL); gtk_toggle_button_set_active (prefs->sa_local_tests_only, bool); @@ -664,7 +671,6 @@ em_mailer_prefs_construct (EMMailerPrefs *prefs) g_signal_connect (prefs->sa_use_daemon, "toggled", G_CALLBACK (settings_changed), prefs); } - GtkWidget * em_mailer_prefs_new (void) { @@ -802,6 +808,8 @@ em_mailer_prefs_apply (EMMailerPrefs *prefs) /* junk prefs */ gconf_client_set_bool (prefs->gconf, "/apps/evolution/mail/junk/check_incoming", gtk_toggle_button_get_active (prefs->check_incoming), NULL); + gconf_client_set_bool (prefs->gconf, "/apps/evolution/mail/junk/check_incoming_imap", + !gtk_toggle_button_get_active (prefs->check_incoming_imap), NULL); gconf_client_set_bool (prefs->gconf, "/apps/evolution/mail/junk/sa/local_only", gtk_toggle_button_get_active (prefs->sa_local_tests_only), NULL); gconf_client_set_bool (prefs->gconf, "/apps/evolution/mail/junk/sa/use_daemon", |