aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/gnome-cal.c
diff options
context:
space:
mode:
authorChenthill Palanisamy <pchenthill@novell.com>2005-04-08 02:12:50 +0800
committerRodrigo Moya <rodrigo@src.gnome.org>2005-04-08 02:12:50 +0800
commitfeafc5987ae184880b3a7fcc54f2f5b3e30dc76a (patch)
tree3cfc30a4510406e970e90c785dee7272d6a19f48 /calendar/gui/gnome-cal.c
parent2ccc37f3d21f348685f18dfda3b125b813669e92 (diff)
downloadgsoc2013-evolution-feafc5987ae184880b3a7fcc54f2f5b3e30dc76a.tar
gsoc2013-evolution-feafc5987ae184880b3a7fcc54f2f5b3e30dc76a.tar.gz
gsoc2013-evolution-feafc5987ae184880b3a7fcc54f2f5b3e30dc76a.tar.bz2
gsoc2013-evolution-feafc5987ae184880b3a7fcc54f2f5b3e30dc76a.tar.lz
gsoc2013-evolution-feafc5987ae184880b3a7fcc54f2f5b3e30dc76a.tar.xz
gsoc2013-evolution-feafc5987ae184880b3a7fcc54f2f5b3e30dc76a.tar.zst
gsoc2013-evolution-feafc5987ae184880b3a7fcc54f2f5b3e30dc76a.zip
If the status is busy call open method again, do not remove the client. IF
2005-04-05 Chenthill Palanisamy <pchenthill@novell.com> * gui/e-cal-model.c: (cal_opened_cb): If the status is busy call open method again, do not remove the client. * gui/gnome-cal.c: (client_cal_opened_cb), (default_client_cal_opened_cb): IF the status is busy and the load_state is not loaded call open method. svn path=/trunk/; revision=29181
Diffstat (limited to 'calendar/gui/gnome-cal.c')
-rw-r--r--calendar/gui/gnome-cal.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/calendar/gui/gnome-cal.c b/calendar/gui/gnome-cal.c
index c36b740d81..cf129a5bf4 100644
--- a/calendar/gui/gnome-cal.c
+++ b/calendar/gui/gnome-cal.c
@@ -2177,6 +2177,7 @@ client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar *gcal)
GnomeCalendarPrivate *priv;
ECalSourceType source_type;
ESource *source;
+ ECalLoadState state;
char *msg;
int i;
@@ -2184,6 +2185,7 @@ client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar *gcal)
source_type = e_cal_get_source_type (ecal);
source = e_cal_get_source (ecal);
+ state = e_cal_get_load_state (ecal);
switch (source_type) {
case E_CAL_SOURCE_TYPE_EVENT:
@@ -2197,9 +2199,12 @@ client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar *gcal)
}
switch (status) {
case E_CALENDAR_STATUS_OK:
+ g_message ("********* the state in ok is %d \n", state);
break;
case E_CALENDAR_STATUS_BUSY:
- e_cal_open_async (ecal, FALSE);
+ g_message ("********* the state is %d \n", state);
+ if (state == E_CAL_LOAD_NOT_LOADED)
+ e_cal_open_async (ecal, FALSE);
return;
case E_CALENDAR_STATUS_INVALID_SERVER_VERSION:
e_error_run (NULL, "calendar:server-version", NULL);
@@ -2268,12 +2273,14 @@ default_client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar
GnomeCalendarPrivate *priv;
ECalSourceType source_type;
ESource *source;
+ ECalLoadState state;
int i;
priv = gcal->priv;
source_type = e_cal_get_source_type (ecal);
source = e_cal_get_source (ecal);
+ state = e_cal_get_load_state (ecal);
switch (source_type) {
case E_CAL_SOURCE_TYPE_EVENT:
@@ -2290,7 +2297,9 @@ default_client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar
case E_CALENDAR_STATUS_OK:
break;
case E_CALENDAR_STATUS_BUSY:
- e_cal_open_async (ecal, FALSE);
+ g_message ("********* the state is %d \n", state);
+ if (state == E_CAL_LOAD_NOT_LOADED)
+ e_cal_open_async (ecal, FALSE);
return;
case E_CALENDAR_STATUS_INVALID_SERVER_VERSION :
e_error_run (NULL, "calendar:server-version", NULL);