[gnome-calendar/search-improvements] search-view: keep a cached count of results
- From: Georges Basile Stavracas Neto <gbsneto src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-calendar/search-improvements] search-view: keep a cached count of results
- Date: Sun, 4 Jan 2015 01:41:57 +0000 (UTC)
commit 142dd9d8d9373636cd04ed8ffec1422d9f32ece3
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date: Sat Jan 3 23:41:48 2015 -0200
search-view: keep a cached count of results
src/gcal-search-view.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/gcal-search-view.c b/src/gcal-search-view.c
index 18bfd7e..bb45e1c 100644
--- a/src/gcal-search-view.c
+++ b/src/gcal-search-view.c
@@ -35,6 +35,7 @@ typedef struct
GtkWidget *no_results_grid;
/* misc */
+ gint num_results;
gchar *time_mask;
gchar *date_mask;
@@ -401,6 +402,7 @@ gcal_search_view_component_added (ECalDataModelSubscriber *subscriber,
grid = make_grid_for_event (GCAL_SEARCH_VIEW (subscriber), GCAL_EVENT_WIDGET (event));
gtk_container_add (GTK_CONTAINER (priv->listbox), grid);
+ priv->num_results++;
}
static void
@@ -451,6 +453,7 @@ gcal_search_view_component_removed (ECalDataModelSubscriber *subscriber,
}
g_list_free (children);
+ priv->num_results--;
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]