aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/gnome-cal.c
diff options
context:
space:
mode:
authorChenthill Palanisamy <pchen@src.gnome.org>2005-10-03 14:16:51 +0800
committerChenthill Palanisamy <pchen@src.gnome.org>2005-10-03 14:16:51 +0800
commit7a102381acf224110cfe32fcc0905a103268abde (patch)
tree3797369272088bdacc8706e1abff2eca92e1bdfe /calendar/gui/gnome-cal.c
parent263e728c125f4312867084d9b85b41caabec6a4f (diff)
downloadgsoc2013-evolution-7a102381acf224110cfe32fcc0905a103268abde.tar
gsoc2013-evolution-7a102381acf224110cfe32fcc0905a103268abde.tar.gz
gsoc2013-evolution-7a102381acf224110cfe32fcc0905a103268abde.tar.bz2
gsoc2013-evolution-7a102381acf224110cfe32fcc0905a103268abde.tar.lz
gsoc2013-evolution-7a102381acf224110cfe32fcc0905a103268abde.tar.xz
gsoc2013-evolution-7a102381acf224110cfe32fcc0905a103268abde.tar.zst
gsoc2013-evolution-7a102381acf224110cfe32fcc0905a103268abde.zip
fixes #264449.
svn path=/trunk/; revision=30467
Diffstat (limited to 'calendar/gui/gnome-cal.c')
-rw-r--r--calendar/gui/gnome-cal.c25
1 files changed, 22 insertions, 3 deletions
diff --git a/calendar/gui/gnome-cal.c b/calendar/gui/gnome-cal.c
index e0e68fb723..a2c62ae152 100644
--- a/calendar/gui/gnome-cal.c
+++ b/calendar/gui/gnome-cal.c
@@ -81,6 +81,7 @@
#include "common/authentication.h"
#include "e-cal-popup.h"
#include "e-cal-menu.h"
+#include "e-cal-model-tasks.h"
/* FIXME glib 2.4 and above has this */
#ifndef G_MAXINT32
@@ -1135,7 +1136,7 @@ update_todo_view (GnomeCalendar *gcal)
model = e_calendar_table_get_model (E_CALENDAR_TABLE (priv->todo));
- if ((sexp = calendar_config_get_hide_completed_tasks_sexp()) != NULL) {
+ if ((sexp = calendar_config_get_hide_completed_tasks_sexp (FALSE)) != NULL) {
priv->todo_sexp = g_strdup_printf ("(and %s %s)", sexp, priv->sexp);
e_cal_model_set_search_query (model, priv->todo_sexp);
g_free (sexp);
@@ -1146,10 +1147,28 @@ update_todo_view (GnomeCalendar *gcal)
}
+static void
+process_completed_tasks (GnomeCalendar *gcal, gboolean config_changed)
+{
+ GnomeCalendarPrivate *priv;
+
+ g_return_if_fail (gcal != NULL);
+ g_return_if_fail (GNOME_IS_CALENDAR(gcal));
+
+ priv = gcal->priv;
+
+ e_calendar_table_process_completed_tasks (E_CALENDAR_TABLE (priv->todo), priv->clients_list[E_CAL_SOURCE_TYPE_TODO], config_changed);
+}
+
static gboolean
update_todo_view_cb (GnomeCalendar *gcal)
{
- update_todo_view(gcal);
+ ECalModel *model;
+
+ model = e_calendar_table_get_model (E_CALENDAR_TABLE (gcal->priv->todo));
+
+ process_completed_tasks (gcal, FALSE);
+ e_cal_model_tasks_update_due_tasks (E_CAL_MODEL_TASKS (model));
return TRUE;
}
@@ -1172,7 +1191,7 @@ update_marcus_bains_line_cb (GnomeCalendar *gcal)
static void
config_hide_completed_tasks_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer data)
{
- update_todo_view (data);
+ process_completed_tasks (data, TRUE);
}
static void