aboutsummaryrefslogtreecommitdiff
path: root/src/datetime-service.c
diff options
context:
space:
mode:
authorMichael Terry <mike@mterry.name>2011-03-03 08:10:00 -0500
committerMichael Terry <mike@mterry.name>2011-03-03 08:10:00 -0500
commitd159692166fb9dfde4deb065f639f76d5586e3f9 (patch)
tree55717873c9668924c5b69a33f203682badf42013 /src/datetime-service.c
parent8dbd819cd5143cb6016b775d0e229819cf324604 (diff)
parentdcb521cd6f42fd8ff289075703cd63aa11a798fb (diff)
downloadayatana-indicator-datetime-d159692166fb9dfde4deb065f639f76d5586e3f9.tar.gz
ayatana-indicator-datetime-d159692166fb9dfde4deb065f639f76d5586e3f9.tar.bz2
ayatana-indicator-datetime-d159692166fb9dfde4deb065f639f76d5586e3f9.zip
merge from trunk; fix utc time always being displayed in manual time spin button
Diffstat (limited to 'src/datetime-service.c')
-rw-r--r--src/datetime-service.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/src/datetime-service.c b/src/datetime-service.c
index 6303a98..078ede0 100644
--- a/src/datetime-service.c
+++ b/src/datetime-service.c
@@ -462,8 +462,7 @@ update_appointment_menu_items (gpointer user_data) {
if (calendar == NULL) return FALSE;
if (!g_settings_get_boolean(conf, SETTINGS_SHOW_EVENTS_S)) return FALSE;
- time_t t1, t2;
- gchar *query, *is, *ie, *ad;
+ gchar *query, *ad;
GList *objects = NULL, *l;
GList *allobjects = NULL;
GSList *g;
@@ -472,13 +471,6 @@ update_appointment_menu_items (gpointer user_data) {
gint width, height;
ESourceList * sources = NULL;
- time(&t1);
- time(&t2);
- t2 += (time_t) (7 * 24 * 60 * 60); /* 7 days ahead of now */
-
- is = isodate_from_time_t(t1);
- ie = isodate_from_time_t(t2);
-
gtk_icon_size_lookup(GTK_ICON_SIZE_MENU, &width, &height);
/* Remove all of the previous appointments */
@@ -497,7 +489,7 @@ update_appointment_menu_items (gpointer user_data) {
// TODO Remove all highlights from the calendar widget
// FIXME can we put a limit on the number of results? Or if not complete, or is event/todo? Or sort it by date?
- query = g_strdup_printf("(occur-in-time-range? (make-time\"%s\") (make-time\"%s\"))", is, ie);
+ query = g_strdup_printf("(occur-in-time-range? (time-now) (time-add-day (time-now) 7))");
if (!e_cal_get_sources(&sources, E_CAL_SOURCE_TYPE_EVENT, &gerror)) {
g_debug("Failed to get ecal sources\n");