aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTed Gould <ted@canonical.com>2009-01-21 09:11:09 -0600
committerTed Gould <ted@canonical.com>2009-01-21 09:11:09 -0600
commitc4877bf1d524ba3573eca0671296c734d7f13f4e (patch)
tree7c6e92cf369b591c7b7540a51f4a5a81e42d8682
parentc84bc2ada92f3371f59785fb1a7a9d61fd9f1ea5 (diff)
downloadayatana-indicator-messages-c4877bf1d524ba3573eca0671296c734d7f13f4e.tar.gz
ayatana-indicator-messages-c4877bf1d524ba3573eca0671296c734d7f13f4e.tar.bz2
ayatana-indicator-messages-c4877bf1d524ba3573eca0671296c734d7f13f4e.zip
Boiler plate IM menu items
-rw-r--r--src/im-menu-item.c49
-rw-r--r--src/im-menu-item.h34
2 files changed, 83 insertions, 0 deletions
diff --git a/src/im-menu-item.c b/src/im-menu-item.c
new file mode 100644
index 0000000..0785c00
--- /dev/null
+++ b/src/im-menu-item.c
@@ -0,0 +1,49 @@
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#include "im-menu-item.h"
+
+typedef struct _ImMenuItemPrivate ImMenuItemPrivate;
+
+struct _ImMenuItemPrivate
+{
+};
+
+#define IM_MENU_ITEM_GET_PRIVATE(o) \
+(G_TYPE_INSTANCE_GET_PRIVATE ((o), IM_MENU_ITEM_TYPE, ImMenuItemPrivate))
+
+static void im_menu_item_class_init (ImMenuItemClass *klass);
+static void im_menu_item_init (ImMenuItem *self);
+static void im_menu_item_dispose (GObject *object);
+static void im_menu_item_finalize (GObject *object);
+
+G_DEFINE_TYPE (ImMenuItem, im_menu_item, GTK_TYPE_MENU_ITEM);
+
+static void
+im_menu_item_class_init (ImMenuItemClass *klass)
+{
+GObjectClass *object_class = G_OBJECT_CLASS (klass);
+
+g_type_class_add_private (klass, sizeof (ImMenuItemPrivate));
+
+object_class->dispose = im_menu_item_dispose;
+object_class->finalize = im_menu_item_finalize;
+}
+
+static void
+im_menu_item_init (ImMenuItem *self)
+{
+}
+
+static void
+im_menu_item_dispose (GObject *object)
+{
+G_OBJECT_CLASS (im_menu_item_parent_class)->dispose (object);
+}
+
+static void
+im_menu_item_finalize (GObject *object)
+{
+G_OBJECT_CLASS (im_menu_item_parent_class)->finalize (object);
+}
diff --git a/src/im-menu-item.h b/src/im-menu-item.h
new file mode 100644
index 0000000..c5fb83e
--- /dev/null
+++ b/src/im-menu-item.h
@@ -0,0 +1,34 @@
+#ifndef __IM_MENU_ITEM_H__
+#define __IM_MENU_ITEM_H__
+
+#include <glib.h>
+#include <glib-object.h>
+
+G_BEGIN_DECLS
+
+#define IM_MENU_ITEM_TYPE (im_menu_item_get_type ())
+#define IM_MENU_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), IM_MENU_ITEM_TYPE, ImMenuItem))
+#define IM_MENU_ITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), IM_MENU_ITEM_TYPE, ImMenuItemClass))
+#define IS_IM_MENU_ITEM(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), IM_MENU_ITEM_TYPE))
+#define IS_IM_MENU_ITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), IM_MENU_ITEM_TYPE))
+#define IM_MENU_ITEM_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), IM_MENU_ITEM_TYPE, ImMenuItemClass))
+
+typedef struct _ImMenuItem ImMenuItem;
+typedef struct _ImMenuItemClass ImMenuItemClass;
+
+struct _ImMenuItemClass
+{
+GtkMenuItemClass parent_class;
+};
+
+struct _ImMenuItem
+{
+GtkMenuItem parent;
+};
+
+GType im_menu_item_get_type (void);
+
+G_END_DECLS
+
+#endif
+