aboutsummaryrefslogtreecommitdiffstats
path: root/e-util
diff options
context:
space:
mode:
authorMichael Meeks <michael@ximian.com>2001-02-21 16:31:28 +0800
committerMichael Meeks <mmeeks@src.gnome.org>2001-02-21 16:31:28 +0800
commit2f099e392d0dfae27282b5d87aa3c5d2acea22de (patch)
tree2a0ab80ea8d3f599b37b1921c368bd6527048789 /e-util
parent0f2a13586b155c0e97eab0b1bc9ab59e5587555d (diff)
downloadgsoc2013-evolution-2f099e392d0dfae27282b5d87aa3c5d2acea22de.tar
gsoc2013-evolution-2f099e392d0dfae27282b5d87aa3c5d2acea22de.tar.gz
gsoc2013-evolution-2f099e392d0dfae27282b5d87aa3c5d2acea22de.tar.bz2
gsoc2013-evolution-2f099e392d0dfae27282b5d87aa3c5d2acea22de.tar.lz
gsoc2013-evolution-2f099e392d0dfae27282b5d87aa3c5d2acea22de.tar.xz
gsoc2013-evolution-2f099e392d0dfae27282b5d87aa3c5d2acea22de.tar.zst
gsoc2013-evolution-2f099e392d0dfae27282b5d87aa3c5d2acea22de.zip
implement.
2001-02-21 Michael Meeks <michael@ximian.com> * gal/util/e-util.h (E_MAKE_X_TYPE): implement. svn path=/trunk/; revision=8315
Diffstat (limited to 'e-util')
-rw-r--r--e-util/e-util.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/e-util/e-util.h b/e-util/e-util.h
index 4e93639e9c..77d056b051 100644
--- a/e-util/e-util.h
+++ b/e-util/e-util.h
@@ -30,6 +30,29 @@ GtkType l##_get_type(void)\
return type;\
}
+
+#define E_MAKE_X_TYPE(l,str,t,ci,i,parent,poa_init,offset) \
+GtkType l##_get_type(void)\
+{\
+ static GtkType type = 0;\
+ if (!type){\
+ GtkTypeInfo info = {\
+ str,\
+ sizeof (t),\
+ sizeof (t##Class),\
+ (GtkClassInitFunc) ci,\
+ (GtkObjectInitFunc) i,\
+ NULL, /* reserved 1 */\
+ NULL, /* reserved 2 */\
+ (GtkClassInitFunc) NULL\
+ };\
+ type = bonobo_x_type_unique (\
+ parent, poa_init, NULL,\
+ offset, &info);\
+ }\
+ return type;\
+}
+
typedef enum {
E_FOCUS_NONE,
E_FOCUS_CURRENT,