[folks: 2/4] Expose the BackendStore's Backends. Helps bgo#628970.
- From: Travis Reitter <treitter src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [folks: 2/4] Expose the BackendStore's Backends. Helps bgo#628970.
- Date: Wed, 15 Sep 2010 15:14:27 +0000 (UTC)
commit 41c8d990629d1ef210a18e2d02ea56ba4a5cce17
Author: Travis Reitter <travis reitter collabora co uk>
Date: Wed Sep 8 09:53:21 2010 -0700
Expose the BackendStore's Backends. Helps bgo#628970.
folks/backend-store.vala | 32 ++++++++++++++++++++++++++++++++
1 files changed, 32 insertions(+), 0 deletions(-)
---
diff --git a/folks/backend-store.vala b/folks/backend-store.vala
index eabd8c8..4035dbb 100644
--- a/folks/backend-store.vala
+++ b/folks/backend-store.vala
@@ -47,11 +47,43 @@ public class Folks.BackendStore : Object {
* This will not be emitted until after { link BackendStore.load_backends}
* has been called.
*
+ * { link Backend}s referenced in this signal are also included in @{link
+ * BackendStore.enabled_backends}.
+ *
* @param backend the new { link Backend}
*/
public signal void backend_available (Backend backend);
/**
+ * The list of backends visible to this store which have not been explicitly
+ * disabled.
+ *
+ * This list will be empty before { link BackendStore.load_backends} has been
+ * called.
+ *
+ * The backends in this list have not necessarily been prepared (see { link
+ * Backend.prepare}).
+ *
+ * @since 0.2.0
+ */
+ public GLib.List<Backend> enabled_backends
+ {
+ owned get
+ {
+ var backends = new GLib.List<Backend> ();
+ foreach (var entry in this.backend_hash)
+ {
+ backends.prepend (entry.value);
+
+ }
+
+ return backends;
+ }
+
+ private set {}
+ }
+
+ /**
* Create a new BackendStore.
*/
public static BackendStore dup ()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]