aboutsummaryrefslogtreecommitdiff
path: root/libindicator/indicator-object.c
diff options
context:
space:
mode:
authorLuke Yelavich <luke.yelavich@canonical.com>2011-01-18 16:50:37 +1100
committerLuke Yelavich <luke.yelavich@canonical.com>2011-01-18 16:50:37 +1100
commit9215e19e801f59a2abd4dd92563cfe50f366f635 (patch)
tree9b4230d2bdc7a7bb1e46e429db8289ce6e8df3fc /libindicator/indicator-object.c
parentab0f0abc3571f801ffff8c42ad87d1e53d6a8ccf (diff)
downloadlibayatana-indicator-9215e19e801f59a2abd4dd92563cfe50f366f635.tar.gz
libayatana-indicator-9215e19e801f59a2abd4dd92563cfe50f366f635.tar.bz2
libayatana-indicator-9215e19e801f59a2abd4dd92563cfe50f366f635.zip
Add accessible_name variable in indicator entry structure
Diffstat (limited to 'libindicator/indicator-object.c')
-rw-r--r--libindicator/indicator-object.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/libindicator/indicator-object.c b/libindicator/indicator-object.c
index 988a8ae..c190cd7 100644
--- a/libindicator/indicator-object.c
+++ b/libindicator/indicator-object.c
@@ -90,6 +90,7 @@ indicator_object_class_init (IndicatorObjectClass *klass)
klass->get_label = NULL;
klass->get_menu = NULL;
klass->get_image = NULL;
+ klass->get_accessible_name = NULL;
klass->get_entries = get_entries_default;
klass->get_location = NULL;
@@ -215,6 +216,7 @@ indicator_object_init (IndicatorObject *self)
self->priv->entry.menu = NULL;
self->priv->entry.label = NULL;
self->priv->entry.image = NULL;
+ self->priv->entry.accessible_name = NULL;
self->priv->gotten_entries = FALSE;
@@ -395,6 +397,14 @@ get_entries_default (IndicatorObject * io)
return NULL;
}
+ if (class->get_accessible_name) {
+ priv->entry.accessible_name = class->get_accessible_name(io);
+ }
+
+ if (priv->entry.accessible_name == NULL) {
+ g_warning("IndicatorObject class does not have an accessible name.");
+ }
+
priv->gotten_entries = TRUE;
}