diff options
author | Sarfraaz Ahmed <asarfraaz@novell.com> | 2005-09-28 22:30:54 +0800 |
---|---|---|
committer | Ahmed Sarfraaz <sarfraaz@src.gnome.org> | 2005-09-28 22:30:54 +0800 |
commit | 5c7e94906345581fdd99c461f0c23cab3b8ebf4b (patch) | |
tree | b70b1d5bc8b8d9b966cc84ec2d4d840640c6cbbd /plugins | |
parent | ebef4e5ed565ae236aed1e644bd62fb475e928f8 (diff) | |
download | gsoc2013-evolution-5c7e94906345581fdd99c461f0c23cab3b8ebf4b.tar.gz gsoc2013-evolution-5c7e94906345581fdd99c461f0c23cab3b8ebf4b.tar.zst gsoc2013-evolution-5c7e94906345581fdd99c461f0c23cab3b8ebf4b.zip |
Propogate the authentication mechanism to the backend. exchange-calendar.c
2005-09-28 Sarfraaz Ahmed <asarfraaz@novell.com>
* exchange-account-setup.c (owa_authenticate_user) : Propogate the
authentication mechanism to the backend.
* exchange-calendar.c
* exchange-contacts.c
* exchange-folder.c : Parse the new account uri.
svn path=/trunk/; revision=30413
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/exchange-operations/ChangeLog | 8 | ||||
-rw-r--r-- | plugins/exchange-operations/exchange-account-setup.c | 4 | ||||
-rw-r--r-- | plugins/exchange-operations/exchange-calendar.c | 16 | ||||
-rw-r--r-- | plugins/exchange-operations/exchange-contacts.c | 8 | ||||
-rw-r--r-- | plugins/exchange-operations/exchange-folder.c | 14 |
5 files changed, 31 insertions, 19 deletions
diff --git a/plugins/exchange-operations/ChangeLog b/plugins/exchange-operations/ChangeLog index 865b2421fe..df7d0de15f 100644 --- a/plugins/exchange-operations/ChangeLog +++ b/plugins/exchange-operations/ChangeLog @@ -1,3 +1,11 @@ +2005-09-28 Sarfraaz Ahmed <asarfraaz@novell.com> + + * exchange-account-setup.c (owa_authenticate_user) : Propogate the + authentication mechanism to the backend. + * exchange-calendar.c + * exchange-contacts.c + * exchange-folder.c : Parse the new account uri. + 2005-09-28 Tor Lillqvist <tml@novell.com> * Makefile.am (INCLUDES, LIBADD): Use just CAMEL_EXCHANGE_CFLAGS diff --git a/plugins/exchange-operations/exchange-account-setup.c b/plugins/exchange-operations/exchange-account-setup.c index e21da51c72..4b291f73c7 100644 --- a/plugins/exchange-operations/exchange-account-setup.c +++ b/plugins/exchange-operations/exchange-account-setup.c @@ -464,6 +464,10 @@ owa_authenticate_user(GtkWidget *button, EConfig *config) which should then be shown using e-error */ owa_url = camel_url_get_param (url, "owa_url"); + if (camel_url_get_param (url, "authmech")) + exchange_params->is_ntlm = TRUE; + else + exchange_params->is_ntlm = FALSE; valid = e2k_validate_user (owa_url, url->user, exchange_params, &remember_password, &result); diff --git a/plugins/exchange-operations/exchange-calendar.c b/plugins/exchange-operations/exchange-calendar.c index 708700ee5f..0117e18af7 100644 --- a/plugins/exchange-operations/exchange-calendar.c +++ b/plugins/exchange-operations/exchange-calendar.c @@ -83,7 +83,7 @@ e_exchange_calendar_get_calendars (ECalSourceType ftype) account = exchange_operations_get_exchange_account (); /* FIXME: Reconsider this hardcoding */ - uri_prefix = g_strconcat ("exchange://", account->account_filename, "/", NULL); + uri_prefix = g_strconcat ("exchange://", account->account_filename, "/;", NULL); prefix_len = strlen (uri_prefix); calendar_list = g_ptr_array_new (); @@ -99,6 +99,7 @@ e_exchange_calendar_get_calendars (ECalSourceType ftype) tmp = (gchar *)e_folder_get_physical_uri (folder); if (g_str_has_prefix (tmp, uri_prefix)) { ruri = g_strdup (tmp+prefix_len); /* ATTN: Shouldn't free this explictly */ + printf ("adding ruri : %s\n", ruri); g_ptr_array_add (calendar_list, (gpointer)ruri); } } @@ -124,7 +125,7 @@ e_exchange_calendar_pcalendar_on_change (GtkTreeView *treeview, ESource *source) gtk_tree_selection_get_selected(selection, &model, &iter); gtk_tree_model_get (model, &iter, CALENDARRURI_COL, &ruri, -1); - es_ruri = g_strconcat (account->account_filename, "/", ruri, NULL); + es_ruri = g_strconcat (account->account_filename, "/;", ruri, NULL); e_source_set_relative_uri (source, es_ruri); g_free (ruri); g_free (es_ruri); @@ -267,7 +268,7 @@ e_exchange_calendar_pcalendar (EPlugin *epl, EConfigHookItemFactoryData *data) int prefix_len; GtkTreeSelection *selection; - uri_prefix = g_strconcat (account->account_filename, "/", NULL); + uri_prefix = g_strconcat (account->account_filename, "/;", NULL); prefix_len = strlen (uri_prefix); tmpruri = (gchar*) rel_uri; @@ -325,6 +326,7 @@ e_exchange_calendar_commit (EPlugin *epl, EConfigTarget *target) int prefix_len; ExchangeAccount *account; ExchangeAccountFolderResult result; + ExchangeConfigListenerStatus status; gint offline_status; uri_text = e_source_get_uri (source); @@ -333,14 +335,12 @@ e_exchange_calendar_commit (EPlugin *epl, EConfigTarget *target) return ; } - exchange_config_listener_get_offline_status (exchange_global_config_listener, - &offline_status); - - if (offline_status == OFFLINE_MODE) + status = exchange_is_offline (&offline_status); + if (offline_status == OFFLINE_MODE || status != CONFIG_LISTENER_STATUS_OK) return; account = exchange_operations_get_exchange_account (); - path_prefix = g_strconcat (account->account_filename, "/", NULL); + path_prefix = g_strconcat (account->account_filename, "/;", NULL); prefix_len = strlen (path_prefix); g_free (path_prefix); diff --git a/plugins/exchange-operations/exchange-contacts.c b/plugins/exchange-operations/exchange-contacts.c index dc1859cee2..ae99fc5566 100644 --- a/plugins/exchange-operations/exchange-contacts.c +++ b/plugins/exchange-operations/exchange-contacts.c @@ -70,7 +70,7 @@ e_exchange_contacts_get_contacts (void) account = exchange_operations_get_exchange_account (); - uri_prefix = g_strconcat ("exchange://", account->account_filename, "/", NULL); + uri_prefix = g_strconcat ("exchange://", account->account_filename, "/;", NULL); prefix_len = strlen (uri_prefix); contacts_list = g_ptr_array_new (); @@ -110,7 +110,7 @@ e_exchange_contacts_pcontacts_on_change (GtkTreeView *treeview, ESource *source) gchar *ruri; gtk_tree_model_get (model, &iter, CONTACTSRURI_COL, &ruri, -1); - es_ruri = g_strconcat (account->account_filename, "/", ruri, NULL); + es_ruri = g_strconcat (account->account_filename, "/;", ruri, NULL); e_source_set_relative_uri (source, es_ruri); g_free (ruri); @@ -250,7 +250,7 @@ e_exchange_contacts_pcontacts (EPlugin *epl, EConfigHookItemFactoryData *data) GtkTreeSelection *selection; tmpruri = (gchar*) rel_uri; - uri_prefix = g_strconcat (account->account_filename, "/", NULL); + uri_prefix = g_strconcat (account->account_filename, "/;", NULL); prefix_len = strlen (uri_prefix); if (g_str_has_prefix (tmpruri, uri_prefix)) { @@ -326,7 +326,7 @@ e_exchange_contacts_commit (EPlugin *epl, EConfigTarget *target) return; account = exchange_operations_get_exchange_account (); - path_prefix = g_strconcat (account->account_filename, "/", NULL); + path_prefix = g_strconcat (account->account_filename, "/;", NULL); prefix_len = strlen (path_prefix); g_free (path_prefix); diff --git a/plugins/exchange-operations/exchange-folder.c b/plugins/exchange-operations/exchange-folder.c index 4e48a66dfd..ab1c419650 100644 --- a/plugins/exchange-operations/exchange-folder.c +++ b/plugins/exchange-operations/exchange-folder.c @@ -87,7 +87,7 @@ org_gnome_exchange_folder_inbox_unsubscribe (EPopup *ep, EPopupItem *p, void *da return; target_uri = g_strdup (target->uri); - path = target->uri + strlen ("exchange://") + strlen (account->account_filename); + path = target->uri + strlen ("exchange://") + strlen (account->account_filename) + strlen ("/;"); /* User will be able to unsubscribe by doing a right click on any one of this two-<other user's>Inbox or the <other user's folder> tree. @@ -175,7 +175,7 @@ exchange_get_folder (char *uri, CamelFolder *folder, void *data) return; /* Get the subscribed folder name. */ - name = target_uri + strlen ("exchange://") + strlen (account->account_filename); + name = target_uri + strlen ("exchange://") + strlen (account->account_filename) + strlen ("/;"); stored_name = strrchr (name + 1, '/'); if (stored_name) @@ -205,7 +205,7 @@ org_gnome_exchange_check_inbox_subscribed (EPlugin *ep, EMPopupTargetFolder *tar if (!account) return; - path = g_strdup_printf (target->uri + strlen ("exchange://") + strlen (account->account_filename)); + path = g_strdup (target->uri + strlen ("exchange://") + strlen (account->account_filename) + strlen ("/;")); sub_folder = strchr (path, '@'); g_free (path); @@ -264,7 +264,7 @@ org_gnome_exchange_check_address_book_subscribed (EPlugin *ep, EABPopupTargetSou return; uri = e_source_get_uri (source); - path = g_strdup_printf (uri + strlen ("exchange://") + strlen (account->account_filename)); + path = g_strdup (uri + strlen ("exchange://") + strlen (account->account_filename) + strlen ("/;")); sub_folder = strchr (path, '@'); if (!sub_folder) { @@ -305,7 +305,7 @@ org_gnome_exchange_check_subscribed (EPlugin *ep, ECalPopupTargetSource *target) return; ruri = (gchar *) e_source_peek_relative_uri (source); - path = g_strdup_printf (ruri + strlen (account->account_filename)); + path = g_strdup (ruri + strlen (account->account_filename) + strlen ("/;")); sub_folder = strchr (path, '@'); if (!sub_folder) { @@ -343,7 +343,7 @@ unsubscribe_dialog_ab_response (GtkDialog *dialog, int response, gpointer data) source = e_source_selector_peek_primary_selection (E_SOURCE_SELECTOR (target->selector)); uri = e_source_get_uri (source); - path = g_strdup_printf (uri + strlen ("exchange://") + strlen (account->account_filename)); + path = g_strdup (uri + strlen ("exchange://") + strlen (account->account_filename) + strlen ("/;")); source_uid = e_source_peek_uid (source); exchange_account_remove_shared_folder (account, path); @@ -385,7 +385,7 @@ unsubscribe_dialog_response (GtkDialog *dialog, int response, gpointer data) ruri = (gchar *) e_source_peek_relative_uri (source); source_uid = e_source_peek_uid (source); - path = g_strdup_printf (ruri + strlen (account->account_filename)); + path = g_strdup (ruri + strlen (account->account_filename) + strlen ("/;")); exchange_account_remove_shared_folder (account, path); ids = gconf_client_get_list (client, CONF_KEY_SELECTED_CAL_SOURCES, |