diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2001-06-02 02:32:53 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2001-06-02 02:32:53 +0800 |
commit | 271fc70bc3375774f84782c4769857b292406de8 (patch) | |
tree | 038e7bddb8e1ef029a8fd4f43fd47de4bf82d1e5 /mail/mail-account-editor.c | |
parent | 53e160a7713f73f14a9fc0e400c2304f7e91ae5f (diff) | |
download | gsoc2013-evolution-271fc70bc3375774f84782c4769857b292406de8.tar.gz gsoc2013-evolution-271fc70bc3375774f84782c4769857b292406de8.tar.zst gsoc2013-evolution-271fc70bc3375774f84782c4769857b292406de8.zip |
Call build_extra_conf() here too. This is when we REALLY want to call it
2001-06-01 Jeffrey Stedfast <fejj@ximian.com>
* mail-account-gui.c (source_type_changed): Call
build_extra_conf() here too. This is when we REALLY want to call
it anyway, not on switch-page because then we'd lose any data on
the Receive Options page if we never switch to that page before
applying the changes.
* mail-account-editor.c (construct): Don't connect to the
switch-page event, instead just call build_extra_conf() here with
the source->url.
svn path=/trunk/; revision=10082
Diffstat (limited to 'mail/mail-account-editor.c')
-rw-r--r-- | mail/mail-account-editor.c | 33 |
1 files changed, 8 insertions, 25 deletions
diff --git a/mail/mail-account-editor.c b/mail/mail-account-editor.c index 58fee4f465..26547915ac 100644 --- a/mail/mail-account-editor.c +++ b/mail/mail-account-editor.c @@ -140,35 +140,16 @@ cancel_clicked (GtkWidget *widget, gpointer data) } static void -switch_page (GtkNotebook *notebook, GtkNotebookPage *page, - int page_num, gpointer user_data) -{ - MailAccountEditor *editor = user_data; - MailConfigService *source = editor->gui->account->source; - MailAccountGuiService *gsrc = &editor->gui->source; - char *url = NULL; - - if (page_num != 2) - return; - - if (gsrc && gsrc->provider && source->url && - !strncmp (gsrc->provider->protocol, source->url, strlen (gsrc->provider->protocol))) - url = source->url; - - mail_account_gui_build_extra_conf (editor->gui, url); -} - -static void construct (MailAccountEditor *editor, MailConfigAccount *account) { + MailConfigService *source = account->source; + editor->gui = mail_account_gui_new (account); - + /* get our toplevel widget and reparent it */ editor->notebook = GTK_NOTEBOOK (glade_xml_get_widget (editor->gui->xml, "account_editor_notebook")); gtk_widget_reparent (GTK_WIDGET (editor->notebook), GNOME_DIALOG (editor)->vbox); - gtk_signal_connect (GTK_OBJECT (editor->notebook), "switch-page", - GTK_SIGNAL_FUNC (switch_page), editor); - + /* give our dialog an OK button and title */ gtk_window_set_title (GTK_WINDOW (editor), _("Evolution Account Editor")); gtk_window_set_policy (GTK_WINDOW (editor), FALSE, TRUE, TRUE); @@ -178,7 +159,7 @@ construct (MailAccountEditor *editor, MailConfigAccount *account) GNOME_STOCK_BUTTON_APPLY, GNOME_STOCK_BUTTON_CANCEL, NULL); - + gnome_dialog_button_connect (GNOME_DIALOG (editor), 0 /* OK */, GTK_SIGNAL_FUNC (ok_clicked), editor); @@ -188,8 +169,10 @@ construct (MailAccountEditor *editor, MailConfigAccount *account) gnome_dialog_button_connect (GNOME_DIALOG (editor), 2 /* CANCEL */, GTK_SIGNAL_FUNC (cancel_clicked), editor); - + mail_account_gui_setup (editor->gui, GTK_WIDGET (editor)); + + mail_account_gui_build_extra_conf (editor->gui, source->url); } MailAccountEditor * |