aboutsummaryrefslogtreecommitdiff
path: root/src/app-indicator.c
diff options
context:
space:
mode:
authorSebastien Bacher <seb128@ubuntu.com>2012-07-11 21:08:16 +0200
committerSebastien Bacher <seb128@ubuntu.com>2012-07-11 21:08:16 +0200
commitdfefc88e26e184b5ab485585b34a663456930746 (patch)
tree165d6fc79d4841668179e5a0e7542f8259cb8ab8 /src/app-indicator.c
parent812ded8224978f47453e53eb63fc11c754bac0c6 (diff)
parentf2744fa7a2ec60767c0fa4b4e358dac86a867ad1 (diff)
downloadlibayatana-appindicator-dfefc88e26e184b5ab485585b34a663456930746.tar.gz
libayatana-appindicator-dfefc88e26e184b5ab485585b34a663456930746.tar.bz2
libayatana-appindicator-dfefc88e26e184b5ab485585b34a663456930746.zip
Import upstream version 12.10.0
Diffstat (limited to 'src/app-indicator.c')
-rw-r--r--src/app-indicator.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/app-indicator.c b/src/app-indicator.c
index 0d6450c..2e98b48 100644
--- a/src/app-indicator.c
+++ b/src/app-indicator.c
@@ -1123,7 +1123,18 @@ bus_get_prop (GDBusConnection * connection, const gchar * sender, const gchar *
} else if (g_strcmp0(property, "AttentionIconName") == 0) {
return g_variant_new_string(priv->attention_icon_name ? priv->attention_icon_name : "");
} else if (g_strcmp0(property, "Title") == 0) {
- return g_variant_new_string(priv->title ? priv->title : "");
+ const gchar * output = NULL;
+ if (priv->title == NULL) {
+ const gchar * name = g_get_application_name();
+ if (name != NULL) {
+ output = name;
+ } else {
+ output = "";
+ }
+ } else {
+ output = priv->title;
+ }
+ return g_variant_new_string(output);
} else if (g_strcmp0(property, "IconThemePath") == 0) {
return g_variant_new_string(priv->icon_theme_path ? priv->icon_theme_path : "");
} else if (g_strcmp0(property, "Menu") == 0) {