From fb328a435358e26c1f2779e2bf07ddb05b60e93e Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 13 Oct 2009 15:37:08 -0500 Subject: Building a basic indicator and the service to go along with it. --- src/indicator-custom.c | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 src/indicator-custom.c (limited to 'src/indicator-custom.c') diff --git a/src/indicator-custom.c b/src/indicator-custom.c new file mode 100644 index 0000000..1a09a9a --- /dev/null +++ b/src/indicator-custom.c @@ -0,0 +1,28 @@ + +#include "libindicator/indicator.h" + +INDICATOR_SET_VERSION +INDICATOR_SET_NAME("indicator-custom") + +GtkLabel * +get_label (void) +{ + return NULL; +} + +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; +} -- cgit v1.2.3