[gnome-photos/wip/rishi/collection: 14/24] base-model: Ignore Filterables that are not search criteria



commit c0ed7299bf38346632879adb0d5ecac31c156c01
Author: Debarshi Ray <debarshir gnome org>
Date:   Thu Jan 11 18:44:09 2018 +0100

    base-model: Ignore Filterables that are not search criteria
    
    https://bugzilla.gnome.org/show_bug.cgi?id=751212

 src/photos-base-model.c | 3 +++
 1 file changed, 3 insertions(+)
---
diff --git a/src/photos-base-model.c b/src/photos-base-model.c
index 119c5b5b..6fbbb898 100644
--- a/src/photos-base-model.c
+++ b/src/photos-base-model.c
@@ -101,6 +101,9 @@ photos_base_model_refresh (PhotosBaseModel *self)
       g_autofree gchar *name = NULL;
 
       object = g_list_model_get_object (G_LIST_MODEL (self->mngr), i);
+      if (!photos_filterable_is_search_criterion (PHOTOS_FILTERABLE (object)))
+        continue;
+
       id = photos_filterable_get_id (PHOTOS_FILTERABLE (object));
       g_object_get (object, "name", &name, NULL);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]