aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2010-08-10 13:49:19 -0500
committerTed Gould <ted@gould.cx>2010-08-10 13:49:19 -0500
commitf04dd0919da6d41443fcea69b4adb83a70fde781 (patch)
treeb1b8532852b7018ef1d70605313a3fa80c645486
parent220d6a305dcfaa0671d7304696f2d8fb1df28431 (diff)
downloadayatana-indicator-application-f04dd0919da6d41443fcea69b4adb83a70fde781.tar.gz
ayatana-indicator-application-f04dd0919da6d41443fcea69b4adb83a70fde781.tar.bz2
ayatana-indicator-application-f04dd0919da6d41443fcea69b4adb83a70fde781.zip
Providing accessors for the ordering_id property
-rw-r--r--src/app-indicator.c43
-rw-r--r--src/app-indicator.h3
2 files changed, 46 insertions, 0 deletions
diff --git a/src/app-indicator.c b/src/app-indicator.c
index 4395452..377fda5 100644
--- a/src/app-indicator.c
+++ b/src/app-indicator.c
@@ -1820,6 +1820,27 @@ app_indicator_set_menu (AppIndicator *self, GtkMenu *menu)
}
/**
+ app_indicator_set_ordering_id:
+ @self: The #AppIndicator
+ @ordering_id: A value for the ordering of this app indicator
+
+ Sets the ordering ID for the app indicator which effects the
+ placement of it on the panel. For almost all app indicator
+ this is not the function you're looking for.
+
+ Wrapper function for property #AppIndicator:ordering-id.
+**/
+void
+app_indicator_set_ordering_id (AppIndicator *self, guint32 ordering_id)
+{
+ g_return_if_fail (IS_APP_INDICATOR (self));
+
+ self->priv->ordering_id = ordering_id;
+
+ return;
+}
+
+/**
app_indicator_get_id:
@self: The #AppIndicator object to use
@@ -1968,3 +1989,25 @@ app_indicator_get_label_guide (AppIndicator *self)
return self->priv->label_guide;
}
+/**
+ app_indicator_get_ordering_id:
+ @self: The #AppIndicator object to use
+
+ Wrapper function for property #AppIndicator:ordering-id.
+
+ Return value: The current ordering ID.
+*/
+guint32
+app_indicator_get_ordering_id (AppIndicator *self)
+{
+ g_return_val_if_fail (IS_APP_INDICATOR (self), 0);
+
+ guint ordering_id = 0;
+
+ g_object_get(G_OBJECT(self),
+ PROP_ORDERING_ID_S, &ordering_id,
+ NULL);
+
+ return ordering_id;
+}
+
diff --git a/src/app-indicator.h b/src/app-indicator.h
index a9e1c38..3cc7cc4 100644
--- a/src/app-indicator.h
+++ b/src/app-indicator.h
@@ -265,6 +265,8 @@ void app_indicator_set_label (AppIndicator
const gchar *guide);
void app_indicator_set_icon_theme_path(AppIndicator *self,
const gchar *icon_theme_path);
+void app_indicator_set_ordering_id (AppIndicator *self,
+ guint32 ordering_id);
/* Get properties */
const gchar * app_indicator_get_id (AppIndicator *self);
@@ -276,6 +278,7 @@ const gchar * app_indicator_get_attention_icon (AppIndicator *
GtkMenu * app_indicator_get_menu (AppIndicator *self);
const gchar * app_indicator_get_label (AppIndicator *self);
const gchar * app_indicator_get_label_guide (AppIndicator *self);
+guint32 app_indicator_get_ordering_id (AppIndicator *self);
G_END_DECLS