aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/e-cal-model.h
diff options
context:
space:
mode:
authorRodrigo Moya <rodrigo@novell.com>2004-08-02 15:33:38 +0800
committerRodrigo Moya <rodrigo@src.gnome.org>2004-08-02 15:33:38 +0800
commit31eb98be3b45881d6208b58982d42aa575e67a1f (patch)
treee1ab4031590896b8787e36b5d7d91f2e1bb71920 /calendar/gui/e-cal-model.h
parent56f7abcb1514da29fd9e6453a7292222742f92f2 (diff)
downloadgsoc2013-evolution-31eb98be3b45881d6208b58982d42aa575e67a1f.tar.gz
gsoc2013-evolution-31eb98be3b45881d6208b58982d42aa575e67a1f.tar.zst
gsoc2013-evolution-31eb98be3b45881d6208b58982d42aa575e67a1f.zip
Fixes #57622
2004-07-30 Rodrigo Moya <rodrigo@novell.com> Fixes #57622 * gui/e-cal-model.h: added ECalModelFlags enum type. * gui/e-cal-model.c (e_cal_model_set_flags, e_cal_model_get_flags): new functions. (e_cal_model_init): initialize the new internal field to keep the flags. (e_cal_view_objects_added_cb): expand recurrences if the model flags contain the EXPAND_RECUR bit. (e_cal_view_objects_modified_cb): if EXPAND_RECUR is on, remove all recurrences and regenerate them. (e_cal_view_objects_removed_cb): remove all instances for given UIDs. (add_new_client): killed warning. (get_dtstart): use the instance_start time when dealing with recurrences. * gui/e-cal-model-calendar.c (get_dtend): use the instance_end time when dealing with recurrences. * gui/e-cal-list-view.c (e_cal_list_view_new): set the EXPAND_RECUR flag on the model for the list view. * gui/e-week-view.c (e_week_view_add_event): * gui/e-day-view.c (e_day_view_add_event): fill in the instance's start and end times in the ECalModelComponent struct. * gui/e-calendar-view.c (e_calendar_view_delete_selected_occurrence): use the instance_start field to retrieve the RECUR-ID, now that all the views fill it in. svn path=/trunk/; revision=26790
Diffstat (limited to 'calendar/gui/e-cal-model.h')
-rw-r--r--calendar/gui/e-cal-model.h16
1 files changed, 13 insertions, 3 deletions
diff --git a/calendar/gui/e-cal-model.h b/calendar/gui/e-cal-model.h
index 846d7b4acd..69feef8842 100644
--- a/calendar/gui/e-cal-model.h
+++ b/calendar/gui/e-cal-model.h
@@ -52,9 +52,16 @@ typedef enum {
E_CAL_MODEL_FIELD_LAST
} ECalModelField;
+typedef enum {
+ E_CAL_MODEL_FLAGS_INVALID = -1,
+ E_CAL_MODEL_FLAGS_EXPAND_RECURRENCES = 0x01
+} ECalModelFlags;
+
typedef struct {
ECal *client;
icalcomponent *icalcomp;
+ time_t instance_start;
+ time_t instance_end;
/* private data */
ECellDateEditValue *dtstart;
@@ -91,6 +98,9 @@ GType e_cal_model_get_type (void);
icalcomponent_kind e_cal_model_get_component_kind (ECalModel *model);
void e_cal_model_set_component_kind (ECalModel *model,
icalcomponent_kind kind);
+ECalModelFlags e_cal_model_get_flags (ECalModel *model);
+void e_cal_model_set_flags (ECalModel *model,
+ ECalModelFlags flags);
icaltimezone *e_cal_model_get_timezone (ECalModel *model);
void e_cal_model_set_timezone (ECalModel *model,
icaltimezone *zone);
@@ -99,11 +109,11 @@ void e_cal_model_set_default_category (ECalModel
gboolean e_cal_model_get_use_24_hour_format (ECalModel *model);
void e_cal_model_set_use_24_hour_format (ECalModel *model,
gboolean use24);
-ECal * e_cal_model_get_default_client (ECalModel *model);
+ECal *e_cal_model_get_default_client (ECalModel *model);
void e_cal_model_set_default_client (ECalModel *model,
ECal *client);
GList *e_cal_model_get_client_list (ECalModel *model);
-ECal * e_cal_model_get_client_for_uri (ECalModel *model,
+ECal *e_cal_model_get_client_for_uri (ECalModel *model,
const char *uri);
void e_cal_model_add_client (ECalModel *model,
ECal *client);
@@ -116,7 +126,7 @@ void e_cal_model_get_time_range (ECalModel
void e_cal_model_set_time_range (ECalModel *model,
time_t start,
time_t end);
-const char * e_cal_model_get_search_query (ECalModel *model);
+const char *e_cal_model_get_search_query (ECalModel *model);
void e_cal_model_set_search_query (ECalModel *model,
const gchar *sexp);
icalcomponent *e_cal_model_create_component_with_defaults (ECalModel *model);