diff options
author | Ted Gould <ted@gould.cx> | 2009-12-18 21:12:20 -0600 |
---|---|---|
committer | Ted Gould <ted@gould.cx> | 2009-12-18 21:12:20 -0600 |
commit | 9e9c366430db392d005442cc503e7cd990ca51c5 (patch) | |
tree | a836fb580e5d1111439038bbbe5343acaf7ff1bc | |
parent | 5be8ede939efb973da4aa7b864fad188803aa650 (diff) | |
parent | d96e16ad7ffdea4807f942ac4b452a6dc607a1fa (diff) | |
download | ayatana-indicator-session-9e9c366430db392d005442cc503e7cd990ca51c5.tar.gz ayatana-indicator-session-9e9c366430db392d005442cc503e7cd990ca51c5.tar.bz2 ayatana-indicator-session-9e9c366430db392d005442cc503e7cd990ca51c5.zip |
Merging in the ubuntu-desktop branch.
-rw-r--r-- | configure.ac | 4 | ||||
-rw-r--r-- | debian/changelog | 39 | ||||
-rw-r--r-- | debian/control | 11 | ||||
-rwxr-xr-x | debian/rules | 1 | ||||
-rw-r--r-- | src/Makefile.am | 4 | ||||
-rw-r--r-- | src/status-provider-mc5.c | 37 |
6 files changed, 75 insertions, 21 deletions
diff --git a/configure.ac b/configure.ac index 536b5af..790029a 100644 --- a/configure.ac +++ b/configure.ac @@ -37,10 +37,10 @@ AC_SUBST(APPLET_CFLAGS) AC_SUBST(APPLET_LIBS) DBUSMENUGLIB_REQUIRED_VERSION=0.1.1 -LIBEMPATHY_REQUIRED_VERSION=2.27.0 +TELEPATHYGLIB_REQUIRED_VERSION=0.9.0 PKG_CHECK_MODULES(STATUSSERVICE, dbusmenu-glib >= $DBUSMENUGLIB_REQUIRED_VERSION - libempathy >= $LIBEMPATHY_REQUIRED_VERSION) + telepathy-glib >= $TELEPATHYGLIB_REQUIRED_VERSION) AC_SUBST(STATUSERVICE_CFLAGS) AC_SUBST(STATUSERVICE_LIBS) diff --git a/debian/changelog b/debian/changelog index 01116cf..274756f 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,42 @@ +indicator-session (0.1.7+r58-0ubuntu1) lucid; urgency=low + + * New snapshot for libindicator 0.3.0 + * debian/control + - build depend on libtelepathy-glib-dev instead of libempathy-dev + - build depend on libindicator-dev >= 0.3.0 + * removed 03_tp_glib.patch and 99_autoreconf.patch, applied upstream + + -- Ken VanDine <ken.vandine@canonical.com> Thu, 10 Dec 2009 10:42:21 -0500 + +indicator-session (0.1.7-0ubuntu5) lucid; urgency=low + + * debian/patches/03_tp_glib.patch + - Updated patch to properly work with TpAccountManager + + -- Ken VanDine <ken.vandine@canonical.com> Tue, 08 Dec 2009 11:01:38 -0500 + +indicator-session (0.1.7-0ubuntu4) lucid; urgency=low + + * debian/patches/02_mc5-fixes.patch + - Renamed the patch for ordering + * debian/patches/03_tp_glib.patch + - Port from libempathy to telepathy-glib (LP: #461367) + * debian/patches/99_autoreconf.patch + - autoreconf for telepathy change + * debian/control + - build depend on libtelepathy-glib-dev instead of libempathy-dev + + -- Ken VanDine <ken.vandine@canonical.com> Tue, 08 Dec 2009 08:58:06 -0500 + +indicator-session (0.2.0~dev-0ubuntu1~ppa2) karmic; urgency=low + + * debian/rules + - removed the extra disable-scrollkeeper arg to configure (LP: #418772) + * debian/control + - removed the build dep for scrollkeeper + + -- Ken VanDine <ken.vandine@canonical.com> Fri, 06 Nov 2009 10:24:06 -0500 + indicator-session (0.2.0~dev-0ubuntu1~ppa1) karmic; urgency=low * Updating to the libindicate 0.3.0 API diff --git a/debian/control b/debian/control index a4f2be7..964bbbb 100644 --- a/debian/control +++ b/debian/control @@ -8,13 +8,12 @@ Build-Depends: debhelper (>= 5.0), libgconf2-dev, libdbus-glib-1-dev, gnome-doc-utils, - scrollkeeper, - libindicator-dev (>= 0.3.0~dev), + libindicator-dev (>= 0.3.0), libdbusmenu-glib-dev (>= 0.1.2), libdbusmenu-gtk-dev (>= 0.1.2), libpolkit-gobject-1-dev, intltool, - libempathy-dev (>= 2.27.0) + libtelepathy-glib-dev (>= 0.9.0) Standards-Version: 3.8.2 Homepage: https://launchpad.net/indicator-session Vcs-Bzr: http://bazaar.launchpad.net/~ubuntu-desktop/indicator-session/ubuntu @@ -28,9 +27,9 @@ Replaces: indicator-sus Description: An indicator showing session management, status and user switching. . This indicator is designed to be placed on the right side of a panel and - give the user easy control for changing their instant message status. Switching - to another user. Starting a guest session. Or controlling the status of - their own session. + give the user easy control for changing their instant message status. + Switching to another user. Starting a guest session. Or controlling the + status of their own session. . It requires some way to be hosted into a panel. For the GNOME Panel the appropriate package is indicator-applet-session. diff --git a/debian/rules b/debian/rules index b632517..8db591a 100755 --- a/debian/rules +++ b/debian/rules @@ -4,7 +4,6 @@ include /usr/share/cdbs/1/rules/debhelper.mk include /usr/share/cdbs/1/class/gnome.mk include /usr/share/cdbs/1/rules/simple-patchsys.mk -DEB_CONFIGURE_EXTRA_FLAGS += --disable-scrollkeeper LDFLAGS += -Wl,-z,defs -Wl,--as-needed DEB_DH_MAKESHLIBS_ARGS = -Xusr/lib/indicators diff --git a/src/Makefile.am b/src/Makefile.am index fefcd37..6a5fc44 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -154,7 +154,9 @@ EXTRA_DIST = \ status-service.xml \ status-provider-mc5.list \ status-provider-pidgin.list \ - status-provider-telepathy.list + status-provider-telepathy.list \ + users-service.xml \ + users-service.list CLEANFILES = \ $(BUILT_SOURCES) diff --git a/src/status-provider-mc5.c b/src/status-provider-mc5.c index 6154fb7..d65a482 100644 --- a/src/status-provider-mc5.c +++ b/src/status-provider-mc5.c @@ -24,7 +24,7 @@ with this program. If not, see <http://www.gnu.org/licenses/>. #include "config.h" #endif -#include "libempathy/empathy-account-manager.h" +#include <telepathy-glib/account-manager.h> #include "status-provider.h" #include "status-provider-mc5.h" @@ -65,7 +65,7 @@ static StatusProviderStatus tp_to_sp_map[TP_CONNECTION_PRESENCE_TYPE_ERROR + 1] typedef struct _StatusProviderMC5Private StatusProviderMC5Private; struct _StatusProviderMC5Private { - EmpathyAccountManager * manager; + TpAccountManager * manager; StatusProviderStatus status; DBusGProxy * dbus_proxy; }; @@ -83,7 +83,7 @@ static void status_provider_mc5_finalize (GObject *object); /* Internal Funcs */ static void set_status (StatusProvider * sp, StatusProviderStatus status); static StatusProviderStatus get_status (StatusProvider * sp); -static void presence_changed (EmpathyAccountManager * eam, guint type, const gchar * type_str, const gchar * message, StatusProviderMC5 * sp); +static void presence_changed (TpAccountManager * eam, guint type, const gchar * type_str, const gchar * message, StatusProviderMC5 * sp); static void dbus_namechange (DBusGProxy * proxy, const gchar * name, const gchar * prev, const gchar * new, StatusProviderMC5 * self); static void mc5_exists_cb (DBusGProxy * proxy, gboolean exists, GError * error, gpointer userdata); @@ -109,25 +109,41 @@ status_provider_mc5_class_init (StatusProviderMC5Class *klass) return; } -/* Build our empathy account manager instance if we don't +/* Build our telepathy account manager instance if we don't have one. */ static void build_eam (StatusProviderMC5 * self) { StatusProviderMC5Private * priv = STATUS_PROVIDER_MC5_GET_PRIVATE(self); + static TpDBusDaemon *daemon = NULL; + GError *error = NULL; if (priv->manager != NULL) { return; } + /* the daemon is used to communicate via DBus */ + daemon = tp_dbus_daemon_dup(&error); - priv->manager = EMPATHY_ACCOUNT_MANAGER(g_object_new(EMPATHY_TYPE_ACCOUNT_MANAGER, NULL)); - g_signal_connect(G_OBJECT(priv->manager), "global-presence-changed", G_CALLBACK(presence_changed), self); + if (daemon == NULL) + { + g_debug("Cannot create DBus daemon: %s\n", error->message); + g_error_free(error); + return; + } + + priv->manager = TP_ACCOUNT_MANAGER (g_object_new (TP_TYPE_ACCOUNT_MANAGER, + "dbus-daemon", daemon, + "dbus-connection", ((TpProxy *) daemon)->dbus_connection, + "bus-name", "org.freedesktop.Telepathy.MissionControl5", + "object-path", "/org/freedesktop/Telepathy/AccountManager", + NULL)); + g_signal_connect(G_OBJECT(priv->manager), "most-available-presence-changed", G_CALLBACK(presence_changed), self); return; } /* Creating an instance of the status provider. We set the variables - and create an EmpathyAccountManager object. It does all the hard + and create an TpAccountManager object. It does all the hard work in this module of tracking MissionControl and enumerating the accounts and all that jazz. */ static void @@ -266,8 +282,7 @@ set_status (StatusProvider * sp, StatusProviderStatus status) StatusProviderMC5Private * priv = STATUS_PROVIDER_MC5_GET_PRIVATE(sp); build_eam(STATUS_PROVIDER_MC5(sp)); - - empathy_account_manager_request_global_presence(priv->manager, sp_to_tp_map[status], sp_to_mc_map[status], ""); + tp_account_manager_set_all_requested_presences(priv->manager, sp_to_tp_map[status], sp_to_mc_map[status], ""); return; } @@ -287,11 +302,11 @@ get_status (StatusProvider * sp) return priv->status; } -/* A signal handler for when the EmpatyAccountManager believes +/* A signal handler for when the TpAccountManager believes that the global status has changed. It roughly calculates this by finding the most available of all accounts that are active. */ static void -presence_changed (EmpathyAccountManager * eam, guint type, const gchar * type_str, const gchar * message, StatusProviderMC5 * sp) +presence_changed (TpAccountManager * eam, guint type, const gchar * type_str, const gchar * message, StatusProviderMC5 * sp) { StatusProviderMC5Private * priv = STATUS_PROVIDER_MC5_GET_PRIVATE(sp); |