evolution-exchange r1613 - in trunk: . calendar
- From: msuman svn gnome org
- To: svn-commits-list gnome org
- Subject: evolution-exchange r1613 - in trunk: . calendar
- Date: Fri, 14 Mar 2008 05:40:13 +0000 (GMT)
Author: msuman
Date: Fri Mar 14 05:40:12 2008
New Revision: 1613
URL: http://svn.gnome.org/viewvc/evolution-exchange?rev=1613&view=rev
Log:
Fix for bug #268259 (bugzilla.novell.com) - Don't require restart of Evolution to create appointment on switching from offline to online mode.
Modified:
trunk/ChangeLog
trunk/calendar/e-cal-backend-exchange.c
Modified: trunk/calendar/e-cal-backend-exchange.c
==============================================================================
--- trunk/calendar/e-cal-backend-exchange.c (original)
+++ trunk/calendar/e-cal-backend-exchange.c Fri Mar 14 05:40:12 2008
@@ -339,7 +339,6 @@
d(printf ("ECBE : cal is offline .. load cache\n"));
-
cbex->priv->read_only = TRUE;
source = e_cal_backend_get_source (E_CAL_BACKEND (cbex));
display_contents = e_source_get_property (source, "offline_sync");
@@ -352,7 +351,6 @@
cbex->account = exchange_component_get_account_for_uri (global_exchange_component, NULL);
if (cbex->account) {
-
exchange_account_set_offline (cbex->account);
if (!exchange_account_connect (cbex->account, NULL, &acresult)) {
cbex->folder = exchange_account_get_folder (cbex->account, uristr);
@@ -384,26 +382,24 @@
/* This steals the ExchangeAccount from ExchangeComponent */
if (!cbex->account) {
cbex->account = exchange_component_get_account_for_uri (global_exchange_component, uristr);
- if (!cbex->account) {
+ if (!cbex->account)
cbex->account = exchange_component_get_account_for_uri (global_exchange_component, NULL);
- exchange_account_set_online (cbex->account);
- if (!exchange_account_connect (cbex->account, password, &acresult)) {
- g_mutex_unlock (cbex->priv->open_lock);
- e_cal_backend_notify_error (E_CAL_BACKEND (cbex), _("Authentication failed"));
- return GNOME_Evolution_Calendar_AuthenticationFailed;
- }
- }
}
- if (exchange_account_get_context (cbex->account)) {
- exchange_account_set_online (cbex->account);
- if(!exchange_account_connect (cbex->account, password, &acresult)) {
- g_mutex_unlock (cbex->priv->open_lock);
- e_cal_backend_notify_error (E_CAL_BACKEND (cbex), _("Authentication failed"));
- return GNOME_Evolution_Calendar_AuthenticationFailed;
- }
+ if (!cbex->account) {
+ g_mutex_unlock (cbex->priv->open_lock);
+ return GNOME_Evolution_Calendar_NoSuchCal;
}
+ exchange_account_connect (cbex->account, password, &acresult);
+ if (acresult != EXCHANGE_ACCOUNT_CONNECT_SUCCESS) {
+ g_mutex_unlock (cbex->priv->open_lock);
+ e_cal_backend_notify_error (E_CAL_BACKEND (cbex), _("Authentication failed"));
+ return GNOME_Evolution_Calendar_AuthenticationFailed;
+ }
+
+ exchange_account_set_online (cbex->account);
+
cbex->folder = exchange_account_get_folder (cbex->account, uristr);
if (!cbex->folder) {
ESource *source;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]