aboutsummaryrefslogtreecommitdiffstats
path: root/mail/mail-account-editor.c
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2001-02-23 05:40:26 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2001-02-23 05:40:26 +0800
commite939da9df48b7e4992de4df915e7832803f8fa12 (patch)
tree2baa5274b6b5601a6560bde5d15f0d7faf6d956b /mail/mail-account-editor.c
parent09515df40565b84e1fdcafce80015b51c0984567 (diff)
downloadgsoc2013-evolution-e939da9df48b7e4992de4df915e7832803f8fa12.tar
gsoc2013-evolution-e939da9df48b7e4992de4df915e7832803f8fa12.tar.gz
gsoc2013-evolution-e939da9df48b7e4992de4df915e7832803f8fa12.tar.bz2
gsoc2013-evolution-e939da9df48b7e4992de4df915e7832803f8fa12.tar.lz
gsoc2013-evolution-e939da9df48b7e4992de4df915e7832803f8fa12.tar.xz
gsoc2013-evolution-e939da9df48b7e4992de4df915e7832803f8fa12.tar.zst
gsoc2013-evolution-e939da9df48b7e4992de4df915e7832803f8fa12.zip
Fixed memory corruption bug.
2001-02-22 Jeffrey Stedfast <fejj@ximian.com> * openpgp-utils.c (openpgp_verify): Fixed memory corruption bug. * mail-format.c (try_inline_pgp_sig): Check to make sure the validity isn't NULL. (handle_multipart_signed): Check for NULL validities. 2001-02-21 Jeffrey Stedfast <fejj@ximian.com> * mail-tools.c (mail_tool_uri_to_folder): Protect against NULL uri's. * mail-vtrash.c: Do mutex locking on the global hash table - this should clear up some segfaults ;-) * mail-config-druid.c (druid_finish): Set the 'enabled' member of the source to TRUE if the URL exists else set to FALSE. (incoming_type_changed): If the provider chosen is "None" then gray-out the auto-check widgets and the check-settings, otherwise sensitize them. * mail-account-editor.c (construct): Added a few more settings. (apply_changes): Save the new settings. * mail-config.c (service_copy): Updated. (config_read): Read in whether or not the account is enabled. (mail_config_write): Save if the account is enabled or not. svn path=/trunk/; revision=8349
Diffstat (limited to 'mail/mail-account-editor.c')
-rw-r--r--mail/mail-account-editor.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/mail/mail-account-editor.c b/mail/mail-account-editor.c
index 5ce5db255b..526f0b57c2 100644
--- a/mail/mail-account-editor.c
+++ b/mail/mail-account-editor.c
@@ -197,6 +197,10 @@ apply_changes (MailAccountEditor *editor)
account->source->save_passwd = GTK_TOGGLE_BUTTON (editor->save_passwd)->active;
account->source->keep_on_server = GTK_TOGGLE_BUTTON (editor->keep_on_server)->active;
+ account->source->enabled = GTK_TOGGLE_BUTTON (editor->source_enabled)->active;
+ account->source->auto_check = GTK_TOGGLE_BUTTON (editor->source_auto_check)->active;
+ account->source->auto_check_time = gtk_spin_button_get_value_as_int (editor->source_auto_timeout);
+
if (editor->source_ssl)
account->source->use_ssl = GTK_TOGGLE_BUTTON (editor->source_ssl)->active;
@@ -542,6 +546,14 @@ transport_type_init (MailAccountEditor *editor, CamelURL *url)
}
static void
+auto_check_toggled (GtkToggleButton *button, gpointer data)
+{
+ MailAccountEditor *editor = data;
+
+ gtk_widget_set_sensitive (GTK_WIDGET (editor->source_auto_timeout), button->active);
+}
+
+static void
source_check (MailAccountEditor *editor, CamelURL *url)
{
GList *providers, *l;
@@ -747,6 +759,15 @@ construct (MailAccountEditor *editor, const MailConfigAccount *account)
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (editor->source_ssl), account->source->use_ssl);
editor->keep_on_server = GTK_CHECK_BUTTON (glade_xml_get_widget (gui, "chkKeepMailOnServer"));
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (editor->keep_on_server), account->source->keep_on_server);
+ editor->source_auto_timeout = GTK_SPIN_BUTTON (glade_xml_get_widget (gui, "spinAutoCheckTimeout"));
+ gtk_spin_button_set_value (editor->source_auto_timeout,
+ (gfloat) (account->source->auto_check_time * 1.0));
+ editor->source_auto_check = GTK_CHECK_BUTTON (glade_xml_get_widget (gui, "chkAutoCheckMail"));
+ gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (editor->source_auto_check), account->source->auto_check);
+ gtk_signal_connect (GTK_OBJECT (editor->source_auto_check), "toggled", auto_check_toggled, editor);
+ gtk_widget_set_sensitive (GTK_WIDGET (editor->source_auto_timeout), account->source->auto_check);
+ editor->source_enabled = GTK_CHECK_BUTTON (glade_xml_get_widget (gui, "chkEnabled"));
+ gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (editor->source_enabled), account->source->enabled);
source_check (editor, url);
source_auth_init (editor, url);
if (url)