[network-manager-applet] applet: add some GNOME Shell debug bits
- From: Dan Williams <dcbw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [network-manager-applet] applet: add some GNOME Shell debug bits
- Date: Thu, 14 Apr 2011 19:29:01 +0000 (UTC)
commit e4aeaa014f04cdfb930b10e5d9f1cd0fa88b2dfb
Author: Dan Williams <dcbw redhat com>
Date: Thu Apr 14 14:29:58 2011 -0500
applet: add some GNOME Shell debug bits
To easily make the applet show up in the indicator area for testing
purposes.
src/applet.c | 4 ++++
src/main.c | 3 +++
2 files changed, 7 insertions(+), 0 deletions(-)
---
diff --git a/src/applet.c b/src/applet.c
index 57d1d35..a01623c 100644
--- a/src/applet.c
+++ b/src/applet.c
@@ -81,6 +81,8 @@
#define NOTIFY_CAPS_ACTIONS_KEY "actions"
+extern gboolean shell_debug;
+
G_DEFINE_TYPE(NMApplet, nma, G_TYPE_OBJECT)
/********************************************************************/
@@ -3056,6 +3058,8 @@ setup_widgets (NMApplet *applet)
applet->status_icon = gtk_status_icon_new ();
if (!applet->status_icon)
return FALSE;
+ if (shell_debug)
+ gtk_status_icon_set_name (applet->status_icon, "adsfasdfasdfadfasdf");
g_signal_connect (applet->status_icon, "notify::screen",
G_CALLBACK (status_icon_screen_changed_cb), applet);
diff --git a/src/main.c b/src/main.c
index 9b056bb..d2a2985 100644
--- a/src/main.c
+++ b/src/main.c
@@ -36,6 +36,7 @@
#include "applet.h"
static GMainLoop *loop = NULL;
+gboolean shell_debug = FALSE;
static void
signal_handler (int signo, siginfo_t *info, void *data)
@@ -85,6 +86,8 @@ int main (int argc, char *argv[])
usage (argv[0]);
exit (0);
}
+ if (!strcmp (argv[i], "--shell-debug"))
+ shell_debug = TRUE;
}
bindtextdomain (GETTEXT_PACKAGE, NMALOCALEDIR);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]