[rygel] tracker: More descriptive names for D-Bus proxies
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [rygel] tracker: More descriptive names for D-Bus proxies
- Date: Mon, 9 Nov 2009 18:46:41 +0000 (UTC)
commit 110efac68126efde42ed8bbc33300fae7bfdbebb
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date: Thu Nov 5 03:06:27 2009 +0200
tracker: More descriptive names for D-Bus proxies
This is mainly to avoid conflicts with (to be added) 'search' method in
the base class, MediaContainer.
.../tracker/rygel-tracker-search-container.vala | 64 ++++++++++----------
1 files changed, 33 insertions(+), 31 deletions(-)
---
diff --git a/src/plugins/tracker/rygel-tracker-search-container.vala b/src/plugins/tracker/rygel-tracker-search-container.vala
index 0e04890..e8d8a11 100644
--- a/src/plugins/tracker/rygel-tracker-search-container.vala
+++ b/src/plugins/tracker/rygel-tracker-search-container.vala
@@ -35,8 +35,8 @@ public class Rygel.TrackerSearchContainer : Rygel.MediaContainer {
private const string SEARCH_PATH = "/org/freedesktop/Tracker/Search";
private const string METADATA_PATH = "/org/freedesktop/Tracker/Metadata";
- public TrackerMetadataIface metadata;
- public TrackerSearchIface search;
+ public TrackerMetadataIface metadata_proxy;
+ public TrackerSearchIface search_proxy;
public string service;
@@ -73,17 +73,18 @@ public class Rygel.TrackerSearchContainer : Rygel.MediaContainer {
// We are performing actual search (though an optimized one) to get
// the hitcount rather than GetHitCount because GetHitCount only
// allows us to get hit count for Text searches.
- var search_result = yield this.search.query (0,
- this.service,
- new string[0],
- "",
- this.keywords,
- this.query_condition,
- false,
- new string[0],
- false,
- 0,
- -1);
+ var search_result = yield this.search_proxy.query (
+ 0,
+ this.service,
+ new string[0],
+ "",
+ this.keywords,
+ this.query_condition,
+ false,
+ new string[0],
+ false,
+ 0,
+ -1);
this.child_count = search_result.length[0];
this.updated ();
@@ -103,17 +104,18 @@ public class Rygel.TrackerSearchContainer : Rygel.MediaContainer {
throws GLib.Error {
string[] keys = TrackerItem.get_metadata_keys ();
- var search_result = yield this.search.query (0,
- this.service,
- keys,
- "",
- this.keywords,
- this.query_condition,
- false,
- new string[0],
- false,
- (int) offset,
- (int) max_count);
+ var search_result = yield this.search_proxy.query (
+ 0,
+ this.service,
+ keys,
+ "",
+ this.keywords,
+ this.query_condition,
+ false,
+ new string[0],
+ false,
+ (int) offset,
+ (int) max_count);
var children = new ArrayList<MediaObject> ();
/* Iterate through all items */
@@ -142,7 +144,7 @@ public class Rygel.TrackerSearchContainer : Rygel.MediaContainer {
string[] keys = TrackerItem.get_metadata_keys ();
- var values = yield this.metadata.get (service, path, keys);
+ var values = yield this.metadata_proxy.get (service, path, keys);
return this.create_item (service, path, values);
}
@@ -204,12 +206,12 @@ public class Rygel.TrackerSearchContainer : Rygel.MediaContainer {
private void create_proxies () throws DBus.Error {
DBus.Connection connection = DBus.Bus.get (DBus.BusType.SESSION);
- this.metadata = connection.get_object (TRACKER_SERVICE,
- METADATA_PATH)
- as TrackerMetadataIface;
- this.search = connection.get_object (TRACKER_SERVICE,
- SEARCH_PATH)
- as TrackerSearchIface;
+ this.metadata_proxy = connection.get_object (TRACKER_SERVICE,
+ METADATA_PATH)
+ as TrackerMetadataIface;
+ this.search_proxy = connection.get_object (TRACKER_SERVICE,
+ SEARCH_PATH)
+ as TrackerSearchIface;
}
/**
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]