From dbf5b1d9ea6aef0fb55ffcd3b6322fbfb20e5e73 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 05:50:34 -0600 Subject: Better displose to free the proxy and ensuring that statuc changes get noted. --- src/status-provider-pidgin.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/status-provider-pidgin.c b/src/status-provider-pidgin.c index 6a3f7a5..5e42ff2 100644 --- a/src/status-provider-pidgin.c +++ b/src/status-provider-pidgin.c @@ -129,6 +129,12 @@ status_provider_pidgin_init (StatusProviderPidgin *self) static void status_provider_pidgin_dispose (GObject *object) { + StatusProviderPidginPrivate * priv = STATUS_PROVIDER_PIDGIN_GET_PRIVATE(self); + + if (priv->proxy != NULL) { + g_object_unref(priv->proxy); + priv->proxy = NULL; + } G_OBJECT_CLASS (status_provider_pidgin_parent_class)->dispose (object); return; @@ -166,6 +172,7 @@ set_status (StatusProvider * sp, StatusProviderStatus status) StatusProviderPidginPrivate * priv = STATUS_PROVIDER_PIDGIN_GET_PRIVATE(sp); pg_status_t pg_status = sp_to_pg_map[status]; priv->pg_status = pg_status; + g_signal_emit(G_OBJECT(sp), signals[STATUS_CHANGED], 0, pg_to_sp_map[priv->pg_status], TRUE); return; } -- cgit v1.2.3 From d61f15d257b8d7e27d4cc7955e9b870d0e44d73b Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 05:55:49 -0600 Subject: Handling the signal better. Now in the header file as well. --- src/status-provider-pidgin.c | 4 ++-- src/status-provider.h | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/status-provider-pidgin.c b/src/status-provider-pidgin.c index 5e42ff2..aaa8732 100644 --- a/src/status-provider-pidgin.c +++ b/src/status-provider-pidgin.c @@ -129,7 +129,7 @@ status_provider_pidgin_init (StatusProviderPidgin *self) static void status_provider_pidgin_dispose (GObject *object) { - StatusProviderPidginPrivate * priv = STATUS_PROVIDER_PIDGIN_GET_PRIVATE(self); + StatusProviderPidginPrivate * priv = STATUS_PROVIDER_PIDGIN_GET_PRIVATE(object); if (priv->proxy != NULL) { g_object_unref(priv->proxy); @@ -172,7 +172,7 @@ set_status (StatusProvider * sp, StatusProviderStatus status) StatusProviderPidginPrivate * priv = STATUS_PROVIDER_PIDGIN_GET_PRIVATE(sp); pg_status_t pg_status = sp_to_pg_map[status]; priv->pg_status = pg_status; - g_signal_emit(G_OBJECT(sp), signals[STATUS_CHANGED], 0, pg_to_sp_map[priv->pg_status], TRUE); + g_signal_emit(G_OBJECT(sp), STATUS_PROVIDER_SIGNAL_STATUS_CHANGED_ID, 0, pg_to_sp_map[priv->pg_status], TRUE); return; } diff --git a/src/status-provider.h b/src/status-provider.h index f01a90e..9cc9885 100644 --- a/src/status-provider.h +++ b/src/status-provider.h @@ -47,7 +47,8 @@ typedef enum } StatusProviderStatus; -#define STATUS_PROVIDER_SIGNAL_STATUS_CHANGED "status-changed" +#define STATUS_PROVIDER_SIGNAL_STATUS_CHANGED "status-changed" +#define STATUS_PROVIDER_SIGNAL_STATUS_CHANGED_ID (g_signal_lookup(STATUS_PROVIDER_SIGNAL_STATUS_CHANGED, STATUS_PROVIDER_TYPE)) typedef struct _StatusProvider StatusProvider; struct _StatusProvider { -- cgit v1.2.3 From e36075a13c2e270b9a240032f8fca244614d6367 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 06:04:11 -0600 Subject: Brining in the concept of global status --- src/status-service.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/src/status-service.c b/src/status-service.c index 4c48c72..3f25c4f 100644 --- a/src/status-service.c +++ b/src/status-service.c @@ -67,6 +67,27 @@ static DbusmenuMenuitem * root_menuitem = NULL; static DbusmenuMenuitem * status_menuitem = NULL; static GMainLoop * mainloop = NULL; static StatusServiceDbus * dbus_interface = NULL; +static StatusProviderStatus global_status = STATUS_PROVIDER_STATUS_OFFLINE; + +static void +status_update (void) { + StatusProviderStatus oldglobal = global_status; + global_status = STATUS_PROVIDER_STATUS_ONLINE; + + int i; + for (i = 0; i < STATUS_PROVIDER_CNT; i++) { + StatusProviderStatus localstatus = status_provider_get_status(status_providers[i]); + if (localstatus > global_status) { + global_status = localstatus; + } + } + + if (global_status != oldglobal) { + g_debug("Global status changed to: %s", _(status_strings[global_status])); + } + + return; +} /* A fun little function to actually lock the screen. If, that's what you want, let's do it! */ -- cgit v1.2.3 From 0788baad4bd4714e8361a99150046ba4fdb4513a Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 06:24:04 -0600 Subject: Global status being used and thrown over d' bus --- src/status-service-dbus.c | 7 +++++++ src/status-service-dbus.h | 1 + src/status-service.c | 5 ++++- 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/src/status-service-dbus.c b/src/status-service-dbus.c index a8e031c..2ac34af 100644 --- a/src/status-service-dbus.c +++ b/src/status-service-dbus.c @@ -172,3 +172,10 @@ _status_service_server_pretty_user_name (StatusServiceDbus * service, gchar ** u return TRUE; } + +void +status_service_dbus_set_status (StatusServiceDbus * self, const gchar * icon) +{ + g_signal_emit(G_OBJECT(self), signals[STATUS_ICONS_CHANGED], 0, icon, TRUE); + return; +} diff --git a/src/status-service-dbus.h b/src/status-service-dbus.h index 66c9206..34a9c3c 100644 --- a/src/status-service-dbus.h +++ b/src/status-service-dbus.h @@ -52,6 +52,7 @@ struct _StatusServiceDbus { }; GType status_service_dbus_get_type (void); +void status_service_dbus_set_status (StatusServiceDbus * self, const gchar * icon); G_END_DECLS diff --git a/src/status-service.c b/src/status-service.c index 3f25c4f..c1f06f5 100644 --- a/src/status-service.c +++ b/src/status-service.c @@ -84,6 +84,9 @@ status_update (void) { if (global_status != oldglobal) { g_debug("Global status changed to: %s", _(status_strings[global_status])); + + dbusmenu_menuitem_property_set(status_menuitem, "label", _(status_strings[global_status])); + status_service_dbus_set_status(dbus_interface, status_icons[global_status]); } return; @@ -175,7 +178,7 @@ build_menu (gpointer data) build_user_item(root); status_menuitem = dbusmenu_menuitem_new(); - dbusmenu_menuitem_property_set(status_menuitem, "label", "Status"); + dbusmenu_menuitem_property_set(status_menuitem, "label", _(status_strings[global_status])); dbusmenu_menuitem_child_append(root, status_menuitem); StatusProviderStatus i; -- cgit v1.2.3 From 255ccc8a16afc58cd56bca5880a706ac494c00ba Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 06:33:22 -0600 Subject: Setting up signal handlers for the signal changing. We still ask everyone, they better cache a value :) --- src/status-service.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/status-service.c b/src/status-service.c index c1f06f5..0c7b7b2 100644 --- a/src/status-service.c +++ b/src/status-service.c @@ -138,8 +138,14 @@ build_providers (gpointer data) int i; for (i = 0; i < STATUS_PROVIDER_CNT; i++) { status_providers[i] = status_provider_newfuncs[i](); + + if (status_providers[i] != NULL) { + g_signal_connect(G_OBJECT(status_providers[i]), STATUS_PROVIDER_SIGNAL_STATUS_CHANGED, G_CALLBACK(status_update), NULL); + } } + status_update(); + return FALSE; } -- cgit v1.2.3 From 77c213e6d61847659df1271312e7398c696f9015 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 06:46:28 -0600 Subject: Adding unistd.h header --- src/status-service.c | 1 + src/users-service.c | 1 + 2 files changed, 2 insertions(+) diff --git a/src/status-service.c b/src/status-service.c index 0c7b7b2..5a9d9b5 100644 --- a/src/status-service.c +++ b/src/status-service.c @@ -23,6 +23,7 @@ with this program. If not, see . #include #include +#include #include diff --git a/src/users-service.c b/src/users-service.c index a8a9c67..9ada91f 100644 --- a/src/users-service.c +++ b/src/users-service.c @@ -20,6 +20,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ +#include #include -- cgit v1.2.3 From 07f10d43e04d0bd7b2e2f614416e43f7b5823f86 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 06:47:27 -0600 Subject: Adding in -Wall and -Werror to things --- src/Makefile.am | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Makefile.am b/src/Makefile.am index ab79f0f..39d360c 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -29,7 +29,7 @@ indicator_status_service_SOURCES = \ status-provider.c \ status-provider-pidgin.h \ status-provider-pidgin.c -indicator_status_service_CFLAGS = $(STATUSSERVICE_CFLAGS) +indicator_status_service_CFLAGS = $(STATUSSERVICE_CFLAGS) -Wall -Werror indicator_status_service_LDADD = $(STATUSSERVICE_LIBS) status-service-client.h: status-service.xml @@ -51,7 +51,7 @@ status-service-server.h: status-service.xml ############### indicator_users_service_SOURCES = users-service.c -indicator_users_service_CFLAGS = $(USERSSERVICE_CFLAGS) +indicator_users_service_CFLAGS = $(USERSSERVICE_CFLAGS) -Wall -Werror indicator_users_service_LDADD = $(USERSSERVICE_LIBS) ################# @@ -59,7 +59,7 @@ indicator_users_service_LDADD = $(USERSSERVICE_LIBS) ################# indicator_session_service_SOURCES = session-service.c -indicator_session_service_CFLAGS = $(SESSIONSERVICE_CFLAGS) -DLIBEXECDIR=\"$(libexecdir)\" +indicator_session_service_CFLAGS = $(SESSIONSERVICE_CFLAGS) -DLIBEXECDIR=\"$(libexecdir)\" -Wall -Werror indicator_session_service_LDADD = $(SESSIONSERVICE_LIBS) ############### -- cgit v1.2.3 From 4e06e6c3d31dbd3fdf23cbb5372f1d33fc09078b Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 06:47:51 -0600 Subject: Unused variable --- src/status-provider.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/status-provider.c b/src/status-provider.c index 1c9561b..83d44ac 100644 --- a/src/status-provider.c +++ b/src/status-provider.c @@ -43,7 +43,7 @@ G_DEFINE_TYPE (StatusProvider, status_provider, G_TYPE_OBJECT); static void status_provider_class_init (StatusProviderClass *klass) { - GObjectClass *object_class = G_OBJECT_CLASS (klass); + // GObjectClass *object_class = G_OBJECT_CLASS (klass); klass->status_changed = NULL; -- cgit v1.2.3 From 8f305c45c5993e38ca76261cbe4135a55b4cfa4d Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 06:48:06 -0600 Subject: Changing the icons to be singular for now. --- src/status-service.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/status-service.xml b/src/status-service.xml index 3807158..ba1f79f 100644 --- a/src/status-service.xml +++ b/src/status-service.xml @@ -7,7 +7,7 @@ - + @@ -18,7 +18,7 @@ - + -- cgit v1.2.3 From b3c64d972bbea808af72124e4b64005329292e4b Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 06:54:10 -0600 Subject: Changing the signal prototype to be strings instead of pointers. --- src/status-service-dbus.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/status-service-dbus.c b/src/status-service-dbus.c index 2ac34af..09d2711 100644 --- a/src/status-service-dbus.c +++ b/src/status-service-dbus.c @@ -102,8 +102,8 @@ status_service_dbus_class_init (StatusServiceDbusClass *klass) G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET(StatusServiceDbusClass, status_icons_changed), NULL, NULL, - g_cclosure_marshal_VOID__POINTER, - G_TYPE_NONE, 1, G_TYPE_POINTER); + g_cclosure_marshal_VOID__STRING, + G_TYPE_NONE, 1, G_TYPE_STRING); dbus_g_object_type_install_info(STATUS_SERVICE_DBUS_TYPE, &dbus_glib__status_service_server_object_info); -- cgit v1.2.3 From 5b09c56f508e40149d9a0bf52b491b0f9fd581ac Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 09:08:33 -0600 Subject: Making dbus names valid, which is a little silly. --- src/dbus-shared-names.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dbus-shared-names.h b/src/dbus-shared-names.h index 3ba21f8..9c828b1 100644 --- a/src/dbus-shared-names.h +++ b/src/dbus-shared-names.h @@ -26,7 +26,7 @@ with this program. If not, see . #define INDICATOR_STATUS_DBUS_NAME "org.ayatana.indicator.status" #define INDICATOR_STATUS_DBUS_OBJECT "/org/ayatana/indicator/status" -#define INDICATOR_STATUS_SERVICE_DBUS_OBJECT "/org/ayatana/indicator/status-service" +#define INDICATOR_STATUS_SERVICE_DBUS_OBJECT "/org/ayatana/indicator/statusservice" #define INDICATOR_USERS_DBUS_NAME "org.ayatana.indicator.users" #define INDICATOR_USERS_DBUS_OBJECT "/org/ayatana/indicator/users" -- cgit v1.2.3 From 839f57951591a4bf9d0ce4fd32b0c5b2d06bf73e Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 09:13:13 -0600 Subject: Showing the icon. Silly. --- src/indicator-sus.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/indicator-sus.c b/src/indicator-sus.c index e248e68..1ab810c 100644 --- a/src/indicator-sus.c +++ b/src/indicator-sus.c @@ -72,6 +72,7 @@ GtkImage * get_icon (void) { GtkImage * image = GTK_IMAGE(gtk_image_new_from_icon_name("user-offline", GTK_ICON_SIZE_MENU)); + gtk_widget_show(GTK_WIDGET(image)); return image; } -- cgit v1.2.3 From 02133f55842b53586b3b9a55bdfd1a73f9cefb62 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 09:15:48 -0600 Subject: releasing version 0.1~ppa7~status1 --- debian/changelog | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index ebd721c..e1c2a2d 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,9 +1,9 @@ -indicator-sus (0.1~ppa7~status1) UNRELEASED; urgency=low +indicator-sus (0.1~ppa7~status1) karmic; urgency=low * Lots of updates from a branch to make things on the status front all happy happy joy joy. - -- Ted Gould Sat, 08 Aug 2009 09:14:41 -0600 + -- Ted Gould Sat, 08 Aug 2009 09:15:44 -0600 indicator-sus (0.1~ppa6) karmic; urgency=low -- cgit v1.2.3 From 0776820b0fad4a18842902c470b263e0913366cc Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 09:39:29 -0600 Subject: Switching icons directory to the one provided by package config --- configure.ac | 3 +++ data/icons/16x16/actions/Makefile.am | 2 +- data/icons/16x16/status/Makefile.am | 2 +- data/icons/22x22/actions/Makefile.am | 2 +- data/icons/22x22/status/Makefile.am | 2 +- data/icons/24x24/actions/Makefile.am | 2 +- data/icons/24x24/status/Makefile.am | 2 +- data/icons/32x32/actions/Makefile.am | 2 +- data/icons/32x32/status/Makefile.am | 2 +- data/icons/48x48/status/Makefile.am | 2 +- data/icons/Makefile.am | 2 +- data/icons/scalable/actions/Makefile.am | 2 +- data/icons/scalable/status/Makefile.am | 2 +- 13 files changed, 15 insertions(+), 12 deletions(-) diff --git a/configure.ac b/configure.ac index 4a6aac4..69ca490 100644 --- a/configure.ac +++ b/configure.ac @@ -67,10 +67,13 @@ AC_ARG_ENABLE(localinstall, AS_HELP_STRING([--enable-localinstall], [install all if test "x$with_localinstall" = "xyes"; then INDICATORDIR="${libdir}/indicators/2/" + INDICATORICONSDIR="${pkgdatadir}/icons/" else INDICATORDIR=`$PKG_CONFIG --variable=indicatordir indicator` + INDICATORICONSDIR=`$PKG_CONFIG --variable=iconsdir indicator` fi AC_SUBST(INDICATORDIR) +AC_SUBST(INDICATORICONSDIR) ########################### # DBus Service Info diff --git a/data/icons/16x16/actions/Makefile.am b/data/icons/16x16/actions/Makefile.am index dd24a1f..bfcc2d9 100644 --- a/data/icons/16x16/actions/Makefile.am +++ b/data/icons/16x16/actions/Makefile.am @@ -1,5 +1,5 @@ -iconsdir = $(pkgdatadir)/icons/hicolor/16x16/actions +iconsdir = $(INDICATORICONSDIR)/hicolor/16x16/actions icons_DATA = \ system-shutdown.png \ diff --git a/data/icons/16x16/status/Makefile.am b/data/icons/16x16/status/Makefile.am index 624ea41..63e3924 100644 --- a/data/icons/16x16/status/Makefile.am +++ b/data/icons/16x16/status/Makefile.am @@ -1,5 +1,5 @@ -iconsdir = $(pkgdatadir)/icons/hicolor/16x16/status +iconsdir = $(INDICATORICONSDIR)/hicolor/16x16/status icons_DATA = \ user-online.png \ diff --git a/data/icons/22x22/actions/Makefile.am b/data/icons/22x22/actions/Makefile.am index 9365485..0b67046 100644 --- a/data/icons/22x22/actions/Makefile.am +++ b/data/icons/22x22/actions/Makefile.am @@ -1,5 +1,5 @@ -iconsdir = $(pkgdatadir)/icons/hicolor/22x22/actions +iconsdir = $(INDICATORICONSDIR)/hicolor/22x22/actions icons_DATA = \ system-shutdown.png \ diff --git a/data/icons/22x22/status/Makefile.am b/data/icons/22x22/status/Makefile.am index 2876545..33f1c26 100644 --- a/data/icons/22x22/status/Makefile.am +++ b/data/icons/22x22/status/Makefile.am @@ -1,5 +1,5 @@ -iconsdir = $(pkgdatadir)/icons/hicolor/22x22/status +iconsdir = $(INDICATORICONSDIR)/hicolor/22x22/status icons_DATA = \ user-online.png \ diff --git a/data/icons/24x24/actions/Makefile.am b/data/icons/24x24/actions/Makefile.am index b90d34c..a460b86 100644 --- a/data/icons/24x24/actions/Makefile.am +++ b/data/icons/24x24/actions/Makefile.am @@ -1,5 +1,5 @@ -iconsdir = $(pkgdatadir)/icons/hicolor/24x24/actions +iconsdir = $(INDICATORICONSDIR)/hicolor/24x24/actions icons_DATA = \ system-shutdown.png \ diff --git a/data/icons/24x24/status/Makefile.am b/data/icons/24x24/status/Makefile.am index 3dd28df..9c0a922 100644 --- a/data/icons/24x24/status/Makefile.am +++ b/data/icons/24x24/status/Makefile.am @@ -1,5 +1,5 @@ -iconsdir = $(pkgdatadir)/icons/hicolor/24x24/status +iconsdir = $(INDICATORICONSDIR)/hicolor/24x24/status icons_DATA = \ user-online.png \ diff --git a/data/icons/32x32/actions/Makefile.am b/data/icons/32x32/actions/Makefile.am index 73b0635..427b0b9 100644 --- a/data/icons/32x32/actions/Makefile.am +++ b/data/icons/32x32/actions/Makefile.am @@ -1,5 +1,5 @@ -iconsdir = $(pkgdatadir)/icons/hicolor/32x32/actions +iconsdir = $(INDICATORICONSDIR)/hicolor/32x32/actions icons_DATA = \ system-restart.png \ diff --git a/data/icons/32x32/status/Makefile.am b/data/icons/32x32/status/Makefile.am index 19e978b..9fd2318 100644 --- a/data/icons/32x32/status/Makefile.am +++ b/data/icons/32x32/status/Makefile.am @@ -1,5 +1,5 @@ -iconsdir = $(pkgdatadir)/icons/hicolor/32x32/status +iconsdir = $(INDICATORICONSDIR)/hicolor/32x32/status icons_DATA = \ user-online.png \ diff --git a/data/icons/48x48/status/Makefile.am b/data/icons/48x48/status/Makefile.am index ec11260..50f5ddf 100644 --- a/data/icons/48x48/status/Makefile.am +++ b/data/icons/48x48/status/Makefile.am @@ -1,5 +1,5 @@ -iconsdir = $(pkgdatadir)/icons/hicolor/48x48/status +iconsdir = $(INDICATORICONSDIR)/hicolor/48x48/status icons_DATA = \ user-online.png \ diff --git a/data/icons/Makefile.am b/data/icons/Makefile.am index 17dca13..7c42753 100644 --- a/data/icons/Makefile.am +++ b/data/icons/Makefile.am @@ -1,6 +1,6 @@ SUBDIRS = scalable 16x16 22x22 24x24 32x32 48x48 -gtk_update_icon_cache = gtk-update-icon-cache -f -t $(pkgdatadir)/icons/hicolor +gtk_update_icon_cache = gtk-update-icon-cache -f -t $(INDICATORICONSDIR)/hicolor install-data-hook: update-icon-cache uninstall-hook: update-icon-cache diff --git a/data/icons/scalable/actions/Makefile.am b/data/icons/scalable/actions/Makefile.am index 10e9dc1..a3b2f14 100644 --- a/data/icons/scalable/actions/Makefile.am +++ b/data/icons/scalable/actions/Makefile.am @@ -1,5 +1,5 @@ -iconsdir = $(pkgdatadir)/icons/hicolor/scalable/actions +iconsdir = $(INDICATORICONSDIR)/hicolor/scalable/actions icons_DATA = \ system-restart.svg \ diff --git a/data/icons/scalable/status/Makefile.am b/data/icons/scalable/status/Makefile.am index 8f4482b..63bfed4 100644 --- a/data/icons/scalable/status/Makefile.am +++ b/data/icons/scalable/status/Makefile.am @@ -1,5 +1,5 @@ -iconsdir = $(pkgdatadir)/icons/hicolor/scalable/status +iconsdir = $(INDICATORICONSDIR)/hicolor/scalable/status icons_DATA = \ user-online.svg \ -- cgit v1.2.3 From 840f181d3e1f0cce77a9460f975f5f3b81b9263f Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 09:44:17 -0600 Subject: Fixing the local install of the icons --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 69ca490..cc30a8e 100644 --- a/configure.ac +++ b/configure.ac @@ -67,7 +67,7 @@ AC_ARG_ENABLE(localinstall, AS_HELP_STRING([--enable-localinstall], [install all if test "x$with_localinstall" = "xyes"; then INDICATORDIR="${libdir}/indicators/2/" - INDICATORICONSDIR="${pkgdatadir}/icons/" + INDICATORICONSDIR="${datadir}/indicator-applet/icons/" else INDICATORDIR=`$PKG_CONFIG --variable=indicatordir indicator` INDICATORICONSDIR=`$PKG_CONFIG --variable=iconsdir indicator` -- cgit v1.2.3 From 695fba351aea9d830525a495c8517e27bdeb1248 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 09:47:04 -0600 Subject: releasing version 0.1~ppa7~status2 --- debian/changelog | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 71d3825..001481a 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,8 @@ -indicator-sus (0.1~ppa7~status2) UNRELEASED; urgency=low +indicator-sus (0.1~ppa7~status2) karmic; urgency=low * Moving the icons to a better, warmer, place. - -- Ted Gould Sat, 08 Aug 2009 09:44:39 -0600 + -- Ted Gould Sat, 08 Aug 2009 09:47:00 -0600 indicator-sus (0.1~ppa7~status1) karmic; urgency=low -- cgit v1.2.3 From c4a5e5cf9dabce8c58bc5e7ef4cfe79095d012df Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 10:47:24 -0600 Subject: Fixing a few things with the dbus stuff and starting to listen to the extra information on the service. --- src/dbus-shared-names.h | 2 +- src/indicator-sus.c | 26 ++++++++++++++++++++++++++ src/status-service-dbus.c | 2 +- src/status-service.xml | 2 +- 4 files changed, 29 insertions(+), 3 deletions(-) diff --git a/src/dbus-shared-names.h b/src/dbus-shared-names.h index 9c828b1..6eb261f 100644 --- a/src/dbus-shared-names.h +++ b/src/dbus-shared-names.h @@ -26,7 +26,7 @@ with this program. If not, see . #define INDICATOR_STATUS_DBUS_NAME "org.ayatana.indicator.status" #define INDICATOR_STATUS_DBUS_OBJECT "/org/ayatana/indicator/status" -#define INDICATOR_STATUS_SERVICE_DBUS_OBJECT "/org/ayatana/indicator/statusservice" +#define INDICATOR_STATUS_SERVICE_DBUS_INTERFACE "org.ayatana.indicator.status.service" #define INDICATOR_USERS_DBUS_NAME "org.ayatana.indicator.users" #define INDICATOR_USERS_DBUS_OBJECT "/org/ayatana/indicator/users" diff --git a/src/indicator-sus.c b/src/indicator-sus.c index 1ab810c..24629d6 100644 --- a/src/indicator-sus.c +++ b/src/indicator-sus.c @@ -47,6 +47,7 @@ static GtkWidget * loading_item = NULL; static DBusGConnection * connection = NULL; static DBusGProxy * proxy = NULL; +static DBusGProxy * status_proxy = NULL; typedef enum { STATUS_SECTION, @@ -179,6 +180,29 @@ status_menu_root_changed(DbusmenuGtkClient * client, DbusmenuMenuitem * newroot, return; } +static gboolean +connect_to_status (gpointer userdata) +{ + if (status_proxy == NULL) { + GError * error = NULL; + + DBusGConnection * sbus = dbus_g_bus_get(DBUS_BUS_SESSION, NULL); + + status_proxy = dbus_g_proxy_new_for_name_owner(sbus, + INDICATOR_STATUS_DBUS_NAME, + INDICATOR_STATUS_DBUS_OBJECT, + INDICATOR_STATUS_SERVICE_DBUS_INTERFACE, + &error); + + if (error != NULL) { + g_warning("Unable to get status proxy: %s", error->message); + g_error_free(error); + } + } + + return FALSE; +} + static gboolean build_status_menu (gpointer userdata) { @@ -209,6 +233,8 @@ build_status_menu (gpointer userdata) gtk_menu_shell_append(GTK_MENU_SHELL(main_menu), status_separator); gtk_widget_hide(status_separator); /* Should be default, I'm just being explicit. $(%*#$ hide already! */ + g_idle_add(connect_to_status, NULL); + return FALSE; } diff --git a/src/status-service-dbus.c b/src/status-service-dbus.c index 09d2711..f93980f 100644 --- a/src/status-service-dbus.c +++ b/src/status-service-dbus.c @@ -116,7 +116,7 @@ status_service_dbus_init (StatusServiceDbus *self) DBusGConnection * connection = dbus_g_bus_get(DBUS_BUS_SESSION, NULL); dbus_g_connection_register_g_object(connection, - INDICATOR_STATUS_SERVICE_DBUS_OBJECT, + INDICATOR_STATUS_DBUS_OBJECT, G_OBJECT(self)); StatusServiceDbusPrivate * priv = STATUS_SERVICE_DBUS_GET_PRIVATE(self); diff --git a/src/status-service.xml b/src/status-service.xml index ba1f79f..977b338 100644 --- a/src/status-service.xml +++ b/src/status-service.xml @@ -1,6 +1,6 @@ - + -- cgit v1.2.3 From e445c0f0ec5bfcf7571f951dfb6889fd2f3558c2 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 10:58:20 -0600 Subject: Oh, now signals and callbacks, oh, my --- src/indicator-sus.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/src/indicator-sus.c b/src/indicator-sus.c index 24629d6..e7b067f 100644 --- a/src/indicator-sus.c +++ b/src/indicator-sus.c @@ -180,6 +180,20 @@ status_menu_root_changed(DbusmenuGtkClient * client, DbusmenuMenuitem * newroot, return; } +void +status_icon_changed (void) +{ + + +} + +void +status_icon_cb (DBusGProxy * proxy, char * icons, GError *error, gpointer userdata) +{ + + return; +} + static gboolean connect_to_status (gpointer userdata) { @@ -197,9 +211,15 @@ connect_to_status (gpointer userdata) if (error != NULL) { g_warning("Unable to get status proxy: %s", error->message); g_error_free(error); + return FALSE; } + + dbus_g_proxy_add_signal(status_proxy, "IconsChanged", G_TYPE_STRING, G_TYPE_INVALID); + dbus_g_proxy_connect_signal(status_proxy, "IconsChanged", G_CALLBACK(status_icon_changed), NULL, NULL); } + org_ayatana_indicator_status_status_icons_async(status_proxy, status_icon_cb, NULL); + return FALSE; } -- cgit v1.2.3 From e522c2c39f2543f1992f6f45879b8ff901b2c3b3 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 11:05:08 -0600 Subject: Setting the icon from the callback of asking the value --- src/indicator-sus.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/src/indicator-sus.c b/src/indicator-sus.c index e7b067f..f33eff0 100644 --- a/src/indicator-sus.c +++ b/src/indicator-sus.c @@ -39,6 +39,7 @@ static DbusmenuGtkClient * users_client = NULL; static DbusmenuGtkClient * session_client = NULL; static GtkMenu * main_menu = NULL; +static GtkImage * status_image = NULL; static GtkWidget * status_separator = NULL; static GtkWidget * users_separator = NULL; @@ -72,9 +73,9 @@ get_label (void) GtkImage * get_icon (void) { - GtkImage * image = GTK_IMAGE(gtk_image_new_from_icon_name("user-offline", GTK_ICON_SIZE_MENU)); - gtk_widget_show(GTK_WIDGET(image)); - return image; + status_image = GTK_IMAGE(gtk_image_new_from_icon_name("user-offline", GTK_ICON_SIZE_MENU)); + gtk_widget_show(GTK_WIDGET(status_image)); + return status_image; } static void @@ -190,6 +191,11 @@ status_icon_changed (void) void status_icon_cb (DBusGProxy * proxy, char * icons, GError *error, gpointer userdata) { + g_return_if_fail(status_image != NULL); + g_return_if_fail(icons != NULL); + g_return_if_fail(icons[0] == '\0'); + + gtk_image_set_from_icon_name(status_image, icons, GTK_ICON_SIZE_MENU); return; } -- cgit v1.2.3 From 74ac9091c44c933e14b6ef05f1177accc744ecf2 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 11:08:03 -0600 Subject: connecting to the signal --- src/indicator-sus.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/indicator-sus.c b/src/indicator-sus.c index f33eff0..3e16e64 100644 --- a/src/indicator-sus.c +++ b/src/indicator-sus.c @@ -181,13 +181,6 @@ status_menu_root_changed(DbusmenuGtkClient * client, DbusmenuMenuitem * newroot, return; } -void -status_icon_changed (void) -{ - - -} - void status_icon_cb (DBusGProxy * proxy, char * icons, GError *error, gpointer userdata) { @@ -200,6 +193,13 @@ status_icon_cb (DBusGProxy * proxy, char * icons, GError *error, gpointer userda return; } +void +status_icon_changed (DBusGProxy * proxy, gchar * icon, gpointer userdata) +{ + return status_icon_cb(proxy, icon, NULL, NULL); +} + + static gboolean connect_to_status (gpointer userdata) { -- cgit v1.2.3 From 65100b2c9570e12729fad8965518193e083842d4 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 13:34:27 -0600 Subject: releasing version 0.1~ppa7~status3 --- debian/changelog | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index e86841a..82c8e6c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,8 @@ -indicator-sus (0.1~ppa7~status3) UNRELEASED; urgency=low +indicator-sus (0.1~ppa7~status3) karmic; urgency=low * Setting the icon from the status service. - -- Ted Gould Sat, 08 Aug 2009 13:33:55 -0600 + -- Ted Gould Sat, 08 Aug 2009 13:34:21 -0600 indicator-sus (0.1~ppa7~status2) karmic; urgency=low -- cgit v1.2.3 From a6b6f4834ff82c11a2f00e16b18049e236cf7946 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 13:43:10 -0600 Subject: API naming change --- src/indicator-sus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/indicator-sus.c b/src/indicator-sus.c index 3e16e64..8c83790 100644 --- a/src/indicator-sus.c +++ b/src/indicator-sus.c @@ -224,7 +224,7 @@ connect_to_status (gpointer userdata) dbus_g_proxy_connect_signal(status_proxy, "IconsChanged", G_CALLBACK(status_icon_changed), NULL, NULL); } - org_ayatana_indicator_status_status_icons_async(status_proxy, status_icon_cb, NULL); + org_ayatana_indicator_status_server_status_icons_async(status_proxy, status_icon_cb, NULL); return FALSE; } -- cgit v1.2.3 From a336d1884c1251fa1745d111db5b8084be8a0d38 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 13:44:15 -0600 Subject: I suck --- src/indicator-sus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/indicator-sus.c b/src/indicator-sus.c index 8c83790..5788d42 100644 --- a/src/indicator-sus.c +++ b/src/indicator-sus.c @@ -224,7 +224,7 @@ connect_to_status (gpointer userdata) dbus_g_proxy_connect_signal(status_proxy, "IconsChanged", G_CALLBACK(status_icon_changed), NULL, NULL); } - org_ayatana_indicator_status_server_status_icons_async(status_proxy, status_icon_cb, NULL); + org_ayatana_indicator_status_service_status_icons_async(status_proxy, status_icon_cb, NULL); return FALSE; } -- cgit v1.2.3 From e00549509eb130648473d1f6536d67b7ffac756a Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 14:19:35 -0600 Subject: Fixing the build system to build the DBus interface better. --- src/Makefile.am | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/Makefile.am b/src/Makefile.am index 39d360c..bc3c9d9 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -32,14 +32,14 @@ indicator_status_service_SOURCES = \ indicator_status_service_CFLAGS = $(STATUSSERVICE_CFLAGS) -Wall -Werror indicator_status_service_LDADD = $(STATUSSERVICE_LIBS) -status-service-client.h: status-service.xml +status-service-client.h: $(srcdir)/status-service.xml dbus-binding-tool \ --prefix=_status_service_client \ --mode=glib-client \ --output=status-service-client.h \ $(srcdir)/status-service.xml -status-service-server.h: status-service.xml +status-service-server.h: $(srcdir)/status-service.xml dbus-binding-tool \ --prefix=_status_service_server \ --mode=glib-server \ @@ -72,3 +72,6 @@ BUILT_SOURCES = \ EXTRA_DIST = \ status-service.xml + +CLEANFILES = \ + $(BUILT_SOURCES) -- cgit v1.2.3 From 98aa89267118f82a759acd3a2c873b39b940899c Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 14:37:04 -0600 Subject: Shuffling around the DBus names so that everything is happier. --- src/dbus-shared-names.h | 7 ++++--- src/indicator-sus.c | 2 +- src/status-service-dbus.c | 2 +- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/dbus-shared-names.h b/src/dbus-shared-names.h index 6eb261f..a645830 100644 --- a/src/dbus-shared-names.h +++ b/src/dbus-shared-names.h @@ -25,13 +25,14 @@ with this program. If not, see . #define __DBUS_SHARED_NAMES_H__ 1 #define INDICATOR_STATUS_DBUS_NAME "org.ayatana.indicator.status" -#define INDICATOR_STATUS_DBUS_OBJECT "/org/ayatana/indicator/status" +#define INDICATOR_STATUS_DBUS_OBJECT "/org/ayatana/indicator/status/menu" +#define INDICATOR_STATUS_SERVICE_DBUS_OBJECT "/org/ayatana/indicator/status/service" #define INDICATOR_STATUS_SERVICE_DBUS_INTERFACE "org.ayatana.indicator.status.service" #define INDICATOR_USERS_DBUS_NAME "org.ayatana.indicator.users" -#define INDICATOR_USERS_DBUS_OBJECT "/org/ayatana/indicator/users" +#define INDICATOR_USERS_DBUS_OBJECT "/org/ayatana/indicator/users/menu" #define INDICATOR_SESSION_DBUS_NAME "org.ayatana.indicator.session" -#define INDICATOR_SESSION_DBUS_OBJECT "/org/ayatana/indicator/session" +#define INDICATOR_SESSION_DBUS_OBJECT "/org/ayatana/indicator/session/menu" #endif /* __DBUS_SHARED_NAMES_H__ */ diff --git a/src/indicator-sus.c b/src/indicator-sus.c index 5788d42..be83c29 100644 --- a/src/indicator-sus.c +++ b/src/indicator-sus.c @@ -210,7 +210,7 @@ connect_to_status (gpointer userdata) status_proxy = dbus_g_proxy_new_for_name_owner(sbus, INDICATOR_STATUS_DBUS_NAME, - INDICATOR_STATUS_DBUS_OBJECT, + INDICATOR_STATUS_SERVICE_DBUS_OBJECT, INDICATOR_STATUS_SERVICE_DBUS_INTERFACE, &error); diff --git a/src/status-service-dbus.c b/src/status-service-dbus.c index f93980f..09d2711 100644 --- a/src/status-service-dbus.c +++ b/src/status-service-dbus.c @@ -116,7 +116,7 @@ status_service_dbus_init (StatusServiceDbus *self) DBusGConnection * connection = dbus_g_bus_get(DBUS_BUS_SESSION, NULL); dbus_g_connection_register_g_object(connection, - INDICATOR_STATUS_DBUS_OBJECT, + INDICATOR_STATUS_SERVICE_DBUS_OBJECT, G_OBJECT(self)); StatusServiceDbusPrivate * priv = STATUS_SERVICE_DBUS_GET_PRIVATE(self); -- cgit v1.2.3 From de34a6f0cdc19b0a4873d15a4b51e8786f31e192 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 14:37:52 -0600 Subject: releasing version 0.1~ppa7~status4 --- debian/changelog | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index f56d5a1..7a1738a 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,9 +1,9 @@ -indicator-sus (0.1~ppa7~status4) UNRELEASED; urgency=low +indicator-sus (0.1~ppa7~status4) karmic; urgency=low * Clean up build a little bit * Change internal DBus names - -- Ted Gould Sat, 08 Aug 2009 14:37:20 -0600 + -- Ted Gould Sat, 08 Aug 2009 14:37:47 -0600 indicator-sus (0.1~ppa7~status3) karmic; urgency=low -- cgit v1.2.3 From c269d95ff563c71713949bbcefd2456bc1b52628 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Sat, 8 Aug 2009 14:54:51 -0600 Subject: Cleaning up icon code so that we save the current one incase someone askes. --- src/status-service-dbus.c | 32 ++++++++++++++++++++++++++++---- 1 file changed, 28 insertions(+), 4 deletions(-) diff --git a/src/status-service-dbus.c b/src/status-service-dbus.c index 09d2711..65de499 100644 --- a/src/status-service-dbus.c +++ b/src/status-service-dbus.c @@ -34,7 +34,7 @@ static void status_service_dbus_init (StatusServiceDbus *self); static void status_service_dbus_dispose (GObject *object); static void status_service_dbus_finalize (GObject *object); static gboolean _status_service_server_watch (StatusServiceDbus * service, GError ** error); -static gboolean _status_service_server_status_icons (StatusServiceDbus * service, GArray * array, GError ** error); +static gboolean _status_service_server_status_icons (StatusServiceDbus * service, gchar ** icon, GError ** error); static gboolean _status_service_server_pretty_user_name (StatusServiceDbus * service, gchar ** username, GError ** error); #include "status-service-server.h" @@ -44,6 +44,7 @@ typedef struct _StatusServiceDbusPrivate StatusServiceDbusPrivate; struct _StatusServiceDbusPrivate { gchar * name; + gchar * icon; }; #define STATUS_SERVICE_DBUS_GET_PRIVATE(o) \ @@ -120,7 +121,8 @@ status_service_dbus_init (StatusServiceDbus *self) G_OBJECT(self)); StatusServiceDbusPrivate * priv = STATUS_SERVICE_DBUS_GET_PRIVATE(self); - priv->name = "test"; + priv->name = NULL; + priv->icon = NULL; return; } @@ -149,8 +151,19 @@ _status_service_server_watch (StatusServiceDbus * service, GError ** error) } static gboolean -_status_service_server_status_icons (StatusServiceDbus * service, GArray * array, GError ** error) +_status_service_server_status_icons (StatusServiceDbus * service, gchar ** icon, GError ** error) { + if (!IS_STATUS_SERVICE_DBUS(service)) { + g_warning("NO BAD EVIL!"); + return FALSE; + } + + StatusServiceDbusPrivate * priv = STATUS_SERVICE_DBUS_GET_PRIVATE(service); + if (priv->icon == NULL) { + *icon = g_strdup(""); + } else { + *icon = g_strdup(priv->icon); + } return TRUE; } @@ -176,6 +189,17 @@ _status_service_server_pretty_user_name (StatusServiceDbus * service, gchar ** u void status_service_dbus_set_status (StatusServiceDbus * self, const gchar * icon) { - g_signal_emit(G_OBJECT(self), signals[STATUS_ICONS_CHANGED], 0, icon, TRUE); + g_return_if_fail(IS_STATUS_SERVICE_DBUS(self)); + + g_debug("Setting icon to: %s", icon); + + StatusServiceDbusPrivate * priv = STATUS_SERVICE_DBUS_GET_PRIVATE(self); + + if (priv->icon != NULL) { + g_free(priv->icon); + } + priv->icon = g_strdup(icon); + + g_signal_emit(G_OBJECT(self), signals[STATUS_ICONS_CHANGED], 0, priv->icon, TRUE); return; } -- cgit v1.2.3 From 8e56c4c1a461ce510d079dc4ab20bc3fda1736e8 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Wed, 12 Aug 2009 21:47:51 -0600 Subject: Some debug messages --- src/indicator-sus.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/indicator-sus.c b/src/indicator-sus.c index be83c29..fcab5cb 100644 --- a/src/indicator-sus.c +++ b/src/indicator-sus.c @@ -73,6 +73,7 @@ get_label (void) GtkImage * get_icon (void) { + g_debug("Changing status icon: %s", "user-offline"); status_image = GTK_IMAGE(gtk_image_new_from_icon_name("user-offline", GTK_ICON_SIZE_MENU)); gtk_widget_show(GTK_WIDGET(status_image)); return status_image; @@ -188,6 +189,7 @@ status_icon_cb (DBusGProxy * proxy, char * icons, GError *error, gpointer userda g_return_if_fail(icons != NULL); g_return_if_fail(icons[0] == '\0'); + g_debug("Changing status icon: %s", icons); gtk_image_set_from_icon_name(status_image, icons, GTK_ICON_SIZE_MENU); return; -- cgit v1.2.3 From 05de808c0cb623e7a2c81006b943da83ee81ebed Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Wed, 12 Aug 2009 21:48:46 -0600 Subject: releasing version 0.1~ppa7~status5 --- debian/changelog | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index a7434b1..3ff4916 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,8 @@ -indicator-sus (0.1~ppa7~status5) UNRELEASED; urgency=low +indicator-sus (0.1~ppa7~status5) karmic; urgency=low * Trying to do some more icon fixes. - -- Ted Gould Wed, 12 Aug 2009 21:48:21 -0600 + -- Ted Gould Wed, 12 Aug 2009 21:48:43 -0600 indicator-sus (0.1~ppa7~status4) karmic; urgency=low -- cgit v1.2.3 From fe0d2f8ccb612af918e4d9783810069c64fae9fe Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Wed, 12 Aug 2009 21:55:02 -0600 Subject: Cleaning up the debug message. --- src/indicator-sus.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/indicator-sus.c b/src/indicator-sus.c index fcab5cb..7c6e66d 100644 --- a/src/indicator-sus.c +++ b/src/indicator-sus.c @@ -73,7 +73,7 @@ get_label (void) GtkImage * get_icon (void) { - g_debug("Changing status icon: %s", "user-offline"); + g_debug("Changing status icon: '%s'", "user-offline"); status_image = GTK_IMAGE(gtk_image_new_from_icon_name("user-offline", GTK_ICON_SIZE_MENU)); gtk_widget_show(GTK_WIDGET(status_image)); return status_image; @@ -189,7 +189,7 @@ status_icon_cb (DBusGProxy * proxy, char * icons, GError *error, gpointer userda g_return_if_fail(icons != NULL); g_return_if_fail(icons[0] == '\0'); - g_debug("Changing status icon: %s", icons); + g_debug("Changing status icon: '%s'", icons); gtk_image_set_from_icon_name(status_image, icons, GTK_ICON_SIZE_MENU); return; -- cgit v1.2.3 From 6e421d043306ac0e72d9760c0d649814f4503d26 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Wed, 12 Aug 2009 22:02:06 -0600 Subject: Oops, wrong signal name. Now better. --- src/indicator-sus.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/indicator-sus.c b/src/indicator-sus.c index 7c6e66d..7a198b2 100644 --- a/src/indicator-sus.c +++ b/src/indicator-sus.c @@ -222,8 +222,8 @@ connect_to_status (gpointer userdata) return FALSE; } - dbus_g_proxy_add_signal(status_proxy, "IconsChanged", G_TYPE_STRING, G_TYPE_INVALID); - dbus_g_proxy_connect_signal(status_proxy, "IconsChanged", G_CALLBACK(status_icon_changed), NULL, NULL); + dbus_g_proxy_add_signal(status_proxy, "StatusIconsChanged", G_TYPE_STRING, G_TYPE_INVALID); + dbus_g_proxy_connect_signal(status_proxy, "StatusIconsChanged", G_CALLBACK(status_icon_changed), NULL, NULL); } org_ayatana_indicator_status_service_status_icons_async(status_proxy, status_icon_cb, NULL); -- cgit v1.2.3 From 629d336c12192ead9693a1ce6a7a665e3d87205e Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Wed, 12 Aug 2009 22:03:20 -0600 Subject: releasing version 0.1~ppa7~status6 --- debian/changelog | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 81aa5c7..1671b59 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,8 @@ -indicator-sus (0.1~ppa7~status6) UNRELEASED; urgency=low +indicator-sus (0.1~ppa7~status6) karmic; urgency=low * Fixing signal name and cleaning debug messages. - -- Ted Gould Wed, 12 Aug 2009 22:02:53 -0600 + -- Ted Gould Wed, 12 Aug 2009 22:03:15 -0600 indicator-sus (0.1~ppa7~status5) karmic; urgency=low -- cgit v1.2.3 From 353afff8d6a75cc564c3e9278b616cf7420cd803 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Wed, 12 Aug 2009 22:23:35 -0600 Subject: Failed logic --- src/indicator-sus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/indicator-sus.c b/src/indicator-sus.c index 7a198b2..07efc86 100644 --- a/src/indicator-sus.c +++ b/src/indicator-sus.c @@ -187,7 +187,7 @@ status_icon_cb (DBusGProxy * proxy, char * icons, GError *error, gpointer userda { g_return_if_fail(status_image != NULL); g_return_if_fail(icons != NULL); - g_return_if_fail(icons[0] == '\0'); + g_return_if_fail(icons[0] != '\0'); g_debug("Changing status icon: '%s'", icons); gtk_image_set_from_icon_name(status_image, icons, GTK_ICON_SIZE_MENU); -- cgit v1.2.3