aboutsummaryrefslogtreecommitdiff
path: root/tests/dummy-indicator-simple.c
diff options
context:
space:
mode:
authorTed Gould <ted@canonical.com>2009-10-28 16:46:25 -0500
committerTed Gould <ted@canonical.com>2009-10-28 16:46:25 -0500
commit0220cc7a435f3f03761697afd316ac1b86a10211 (patch)
treed612bfedf1888385c5e5e6a5c7d0f3c530f19dcb /tests/dummy-indicator-simple.c
parentb5f41d1c0ca30f1cf7379e754d906681ccfbe9e1 (diff)
parentb98a4811a0b03335da1fad3d0e0bce08bdad2a00 (diff)
downloadlibayatana-indicator-0220cc7a435f3f03761697afd316ac1b86a10211.tar.gz
libayatana-indicator-0220cc7a435f3f03761697afd316ac1b86a10211.tar.bz2
libayatana-indicator-0220cc7a435f3f03761697afd316ac1b86a10211.zip
Grabbing the loader branch
Diffstat (limited to 'tests/dummy-indicator-simple.c')
-rw-r--r--tests/dummy-indicator-simple.c28
1 files changed, 28 insertions, 0 deletions
diff --git a/tests/dummy-indicator-simple.c b/tests/dummy-indicator-simple.c
new file mode 100644
index 0000000..cee4eac
--- /dev/null
+++ b/tests/dummy-indicator-simple.c
@@ -0,0 +1,28 @@
+
+#include "libindicator/indicator.h"
+
+INDICATOR_SET_VERSION
+INDICATOR_SET_NAME("dummy-indicator-simple")
+
+GtkLabel *
+get_label (void)
+{
+ return GTK_LABEL(gtk_label_new("Simple Item"));
+}
+
+GtkImage *
+get_icon (void)
+{
+ return GTK_IMAGE(gtk_image_new());
+}
+
+GtkMenu *
+get_menu (void)
+{
+ GtkMenu * main_menu = GTK_MENU(gtk_menu_new());
+ GtkWidget * loading_item = gtk_menu_item_new_with_label("Loading...");
+ gtk_menu_shell_append(GTK_MENU_SHELL(main_menu), loading_item);
+ gtk_widget_show(GTK_WIDGET(loading_item));
+
+ return main_menu;
+}