aboutsummaryrefslogtreecommitdiff
path: root/libdbusmenu-gtk
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2009-12-15 16:04:29 -0600
committerTed Gould <ted@gould.cx>2009-12-15 16:04:29 -0600
commitf70759b6c1a61e34660a3bc2dddfb3f2cbf18fe7 (patch)
tree51f31fc30f1f1f5e0da5534b0926b24892029fcb /libdbusmenu-gtk
parentb0478abc4d87214dcc19bfd1c3d101c19b2990e5 (diff)
downloadlibdbusmenu-f70759b6c1a61e34660a3bc2dddfb3f2cbf18fe7.tar.gz
libdbusmenu-f70759b6c1a61e34660a3bc2dddfb3f2cbf18fe7.tar.bz2
libdbusmenu-f70759b6c1a61e34660a3bc2dddfb3f2cbf18fe7.zip
Building the basic generic menu item.
Diffstat (limited to 'libdbusmenu-gtk')
-rw-r--r--libdbusmenu-gtk/Makefile.am2
-rw-r--r--libdbusmenu-gtk/genericmenuitem.c49
-rw-r--r--libdbusmenu-gtk/genericmenuitem.h34
3 files changed, 85 insertions, 0 deletions
diff --git a/libdbusmenu-gtk/Makefile.am b/libdbusmenu-gtk/Makefile.am
index 87a82a6..97d8563 100644
--- a/libdbusmenu-gtk/Makefile.am
+++ b/libdbusmenu-gtk/Makefile.am
@@ -15,6 +15,8 @@ libdbusmenu_gtkinclude_HEADERS = \
libdbusmenu_gtk_la_SOURCES = \
client.h \
client.c \
+ genericmenuitem.h \
+ genericmenuitem.c \
menu.h \
menu.c \
menuitem.h \
diff --git a/libdbusmenu-gtk/genericmenuitem.c b/libdbusmenu-gtk/genericmenuitem.c
new file mode 100644
index 0000000..3dd3969
--- /dev/null
+++ b/libdbusmenu-gtk/genericmenuitem.c
@@ -0,0 +1,49 @@
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#include "genericmenuitem.h"
+
+typedef struct _GenericmenuitemPrivate GenericmenuitemPrivate;
+
+struct _GenericmenuitemPrivate
+{
+};
+
+#define GENERICMENUITEM_GET_PRIVATE(o) \
+(G_TYPE_INSTANCE_GET_PRIVATE ((o), GENERICMENUITEM_TYPE, GenericmenuitemPrivate))
+
+static void genericmenuitem_class_init (GenericmenuitemClass *klass);
+static void genericmenuitem_init (Genericmenuitem *self);
+static void genericmenuitem_dispose (GObject *object);
+static void genericmenuitem_finalize (GObject *object);
+
+G_DEFINE_TYPE (Genericmenuitem, genericmenuitem, GTK_TYPE_CHECK_MENU_ITEM);
+
+static void
+genericmenuitem_class_init (GenericmenuitemClass *klass)
+{
+GObjectClass *object_class = G_OBJECT_CLASS (klass);
+
+g_type_class_add_private (klass, sizeof (GenericmenuitemPrivate));
+
+object_class->dispose = genericmenuitem_dispose;
+object_class->finalize = genericmenuitem_finalize;
+}
+
+static void
+genericmenuitem_init (Genericmenuitem *self)
+{
+}
+
+static void
+genericmenuitem_dispose (GObject *object)
+{
+G_OBJECT_CLASS (genericmenuitem_parent_class)->dispose (object);
+}
+
+static void
+genericmenuitem_finalize (GObject *object)
+{
+G_OBJECT_CLASS (genericmenuitem_parent_class)->finalize (object);
+}
diff --git a/libdbusmenu-gtk/genericmenuitem.h b/libdbusmenu-gtk/genericmenuitem.h
new file mode 100644
index 0000000..fdfbee1
--- /dev/null
+++ b/libdbusmenu-gtk/genericmenuitem.h
@@ -0,0 +1,34 @@
+#ifndef __GENERICMENUITEM_H__
+#define __GENERICMENUITEM_H__
+
+#include <glib.h>
+#include <glib-object.h>
+#include <gtk/gtk.h>
+
+G_BEGIN_DECLS
+
+#define GENERICMENUITEM_TYPE (genericmenuitem_get_type ())
+#define GENERICMENUITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GENERICMENUITEM_TYPE, Genericmenuitem))
+#define GENERICMENUITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GENERICMENUITEM_TYPE, GenericmenuitemClass))
+#define IS_GENERICMENUITEM(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GENERICMENUITEM_TYPE))
+#define IS_GENERICMENUITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GENERICMENUITEM_TYPE))
+#define GENERICMENUITEM_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GENERICMENUITEM_TYPE, GenericmenuitemClass))
+
+typedef struct _Genericmenuitem Genericmenuitem;
+typedef struct _GenericmenuitemClass GenericmenuitemClass;
+
+struct _GenericmenuitemClass
+{
+GtkCheckMenuItemClass parent_class;
+};
+
+struct _Genericmenuitem
+{
+GtkCheckMenuItem parent;
+};
+
+GType genericmenuitem_get_type (void);
+
+G_END_DECLS
+
+#endif