tracker r1491 - in branches/xesam-support: . src/trackerd
- From: pvanhoof svn gnome org
- To: svn-commits-list gnome org
- Subject: tracker r1491 - in branches/xesam-support: . src/trackerd
- Date: Tue, 27 May 2008 09:03:29 +0000 (UTC)
Author: pvanhoof
Date: Tue May 27 09:03:29 2008
New Revision: 1491
URL: http://svn.gnome.org/viewvc/tracker?rev=1491&view=rev
Log:
2008-05-27 Philip Van Hoof <pvanhoof gnome org>
* Fixed the Xesam DBus namespaces for Xesam r0.95
Modified:
branches/xesam-support/ChangeLog
branches/xesam-support/src/trackerd/tracker-dbus-xesam.h
branches/xesam-support/src/trackerd/tracker-dbus.c
branches/xesam-support/src/trackerd/tracker-dbus.h
branches/xesam-support/src/trackerd/tracker-main.c
Modified: branches/xesam-support/src/trackerd/tracker-dbus-xesam.h
==============================================================================
--- branches/xesam-support/src/trackerd/tracker-dbus-xesam.h (original)
+++ branches/xesam-support/src/trackerd/tracker-dbus-xesam.h Tue May 27 09:03:29 2008
@@ -29,8 +29,8 @@
#include "tracker-db-sqlite.h"
#include "tracker-indexer.h"
-#define TRACKER_DBUS_XESAM_SERVICE "org.freedesktop.xesam"
-#define TRACKER_DBUS_XESAM_PATH "/org/freedesktop/xesam/Search"
+#define TRACKER_DBUS_XESAM_SERVICE "org.freedesktop.xesam.searcher"
+#define TRACKER_DBUS_XESAM_PATH "/org/freedesktop/xesam/searcher/main"
#define TRACKER_DBUS_XESAM_INTERFACE "org.freedesktop.xesam.Search"
G_BEGIN_DECLS
Modified: branches/xesam-support/src/trackerd/tracker-dbus.c
==============================================================================
--- branches/xesam-support/src/trackerd/tracker-dbus.c (original)
+++ branches/xesam-support/src/trackerd/tracker-dbus.c Tue May 27 09:03:29 2008
@@ -127,10 +127,11 @@
gboolean
tracker_dbus_preinit (Tracker *tracker,
DBusGConnection **connection_out,
- DBusGProxy **proxy_out)
+ DBusGProxy **proxy_out,
+ DBusGProxy **xesam_out)
{
DBusGConnection *connection;
- DBusGProxy *proxy;
+ DBusGProxy *proxy, *xesam;
GError *error = NULL;
g_return_val_if_fail (tracker != NULL, FALSE);
@@ -158,8 +159,22 @@
return FALSE;
}
+ /* The definitions below (DBUS_SERVICE_DBUS, etc) are
+ * predefined for us to just use.
+ */
+ xesam = dbus_g_proxy_new_for_name (connection,
+ DBUS_SERVICE_DBUS,
+ DBUS_PATH_DBUS,
+ DBUS_INTERFACE_DBUS);
+
+ /* Set up the main tracker service */
+ if (!dbus_register_service (xesam, TRACKER_DBUS_XESAM_SERVICE)) {
+ return FALSE;
+ }
+
*connection_out = connection;
*proxy_out = proxy;
+ *xesam_out = xesam;
return TRUE;
}
@@ -167,7 +182,8 @@
gboolean
tracker_dbus_init (Tracker *tracker,
DBusGConnection *connection,
- DBusGProxy *proxy)
+ DBusGProxy *proxy,
+ DBusGProxy *xesam)
{
GObject *object;
DBConnection *db_connection;
@@ -252,7 +268,7 @@
if (tracker_config_get_enable_xesam (tracker->config)) {
/* Add org.freedesktop.xesam.Search */
if (!(object = dbus_register_object (connection,
- proxy,
+ xesam,
TRACKER_TYPE_DBUS_XESAM,
&dbus_glib_tracker_dbus_xesam_object_info,
TRACKER_DBUS_XESAM_PATH))) {
Modified: branches/xesam-support/src/trackerd/tracker-dbus.h
==============================================================================
--- branches/xesam-support/src/trackerd/tracker-dbus.h (original)
+++ branches/xesam-support/src/trackerd/tracker-dbus.h Tue May 27 09:03:29 2008
@@ -80,10 +80,12 @@
gboolean tracker_dbus_preinit (Tracker *tracker,
DBusGConnection **connection_out,
- DBusGProxy **proxy_out);
+ DBusGProxy **proxy_out,
+ DBusGProxy **xesam_out);
gboolean tracker_dbus_init (Tracker *tracker,
DBusGConnection *connection,
- DBusGProxy *proxy);
+ DBusGProxy *proxy,
+ DBusGProxy *xesam);
void tracker_dbus_shutdown (void);
guint tracker_dbus_get_next_request_id (void);
GObject * tracker_dbus_get_object (GType type);
Modified: branches/xesam-support/src/trackerd/tracker-main.c
==============================================================================
--- branches/xesam-support/src/trackerd/tracker-main.c (original)
+++ branches/xesam-support/src/trackerd/tracker-main.c Tue May 27 09:03:29 2008
@@ -809,6 +809,7 @@
{
DBusGConnection *connection = NULL;
DBusGProxy *proxy = NULL;
+ DBusGProxy *xesam = NULL;
GOptionContext *context = NULL;
GError *error = NULL;
GThread *thread;
@@ -938,7 +939,7 @@
tracker_config_get_verbosity (tracker->config));
g_message ("Starting log");
- if (!tracker_dbus_preinit (tracker, &connection, &proxy))
+ if (!tracker_dbus_preinit (tracker, &connection, &proxy, &xesam))
return EXIT_FAILURE;
sanity_check_option_values ();
@@ -993,7 +994,7 @@
/* If we are already running, this should return some
* indication.
*/
- if (!tracker_dbus_init (tracker, connection, proxy)) {
+ if (!tracker_dbus_init (tracker, connection, proxy, xesam)) {
return EXIT_FAILURE;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]