[gnome-photos] collection-manager: Add photos_collection_manager_get_where
- From: Debarshi Ray <debarshir src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-photos] collection-manager: Add photos_collection_manager_get_where
- Date: Tue, 2 Apr 2013 22:38:39 +0000 (UTC)
commit 41affd585f890991c849d552fcc95cbb8b7be3b2
Author: Debarshi Ray <debarshir gnome org>
Date: Tue Apr 2 15:52:50 2013 +0200
collection-manager: Add photos_collection_manager_get_where
src/photos-collection-manager.c | 16 +++++++++++++++-
src/photos-collection-manager.h | 4 +++-
2 files changed, 18 insertions(+), 2 deletions(-)
---
diff --git a/src/photos-collection-manager.c b/src/photos-collection-manager.c
index 22f070f..12c1236 100644
--- a/src/photos-collection-manager.c
+++ b/src/photos-collection-manager.c
@@ -1,6 +1,6 @@
/*
* Photos - access, organize and share your photos on GNOME
- * Copyright © 2012 Red Hat, Inc.
+ * Copyright © 2012, 2013 Red Hat, Inc.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
@@ -27,6 +27,7 @@
#include <glib.h>
+#include "photos-base-item.h"
#include "photos-collection-manager.h"
@@ -72,3 +73,16 @@ photos_collection_manager_new (void)
{
return g_object_new (PHOTOS_TYPE_COLLECTION_MANAGER, NULL);
}
+
+
+gchar *
+photos_collection_manager_get_where (PhotosCollectionManager *self)
+{
+ GObject *collection;
+
+ collection = photos_base_manager_get_active_object (PHOTOS_BASE_MANAGER (self));
+ if (collection == NULL)
+ return g_strdup ("");
+
+ return photos_base_item_get_where (PHOTOS_BASE_ITEM (collection));
+}
diff --git a/src/photos-collection-manager.h b/src/photos-collection-manager.h
index 7d7a92f..535eec6 100644
--- a/src/photos-collection-manager.h
+++ b/src/photos-collection-manager.h
@@ -1,6 +1,6 @@
/*
* Photos - access, organize and share your photos on GNOME
- * Copyright © 2012 Red Hat, Inc.
+ * Copyright © 2012, 2013 Red Hat, Inc.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
@@ -70,6 +70,8 @@ GType photos_collection_manager_get_type (void) G_
PhotosBaseManager *photos_collection_manager_new (void);
+gchar *photos_collection_manager_get_where (PhotosCollectionManager *self);
+
G_END_DECLS
#endif /* PHOTOS_COLLECTION_MANAGER_H */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]