[rygel] tracker: Keep only one hierarchy
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [rygel] tracker: Keep only one hierarchy
- Date: Mon, 15 Nov 2010 13:22:11 +0000 (UTC)
commit a6c2fb304726387815e5db38dd726a92e1f73056
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date: Mon Nov 15 15:17:27 2010 +0200
tracker: Keep only one hierarchy
src/plugins/tracker/rygel-tracker-plugin.vala | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
---
diff --git a/src/plugins/tracker/rygel-tracker-plugin.vala b/src/plugins/tracker/rygel-tracker-plugin.vala
index bff2652..2755393 100644
--- a/src/plugins/tracker/rygel-tracker-plugin.vala
+++ b/src/plugins/tracker/rygel-tracker-plugin.vala
@@ -23,6 +23,8 @@
using Gee;
public class Rygel.Tracker.Plugin : Rygel.MediaServerPlugin {
+ private static RootContainer root_container;
+
public Plugin () {
base ("Tracker",
// @REALNAME@ is substituted for user's real name
@@ -31,7 +33,11 @@ public class Rygel.Tracker.Plugin : Rygel.MediaServerPlugin {
}
public override MediaContainer? get_root_container (GUPnP.Context context) {
- return new RootContainer (this.title);
+ if (root_container == null) {
+ root_container = new RootContainer (this.title);
+ }
+
+ return root_container;
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]