* Free Software Foundation, Inc., 59 Temple Place, Suite 330,
* Boston, MA 02111-1307, USA.
*/
+#if !defined (__GLIB_GOBJECT_H_INSIDE__) && !defined (GOBJECT_COMPILATION)
+#error "Only <glib-object.h> can be included directly."
+#endif
+
#ifndef __G_CLOSURE_H__
#define __G_CLOSURE_H__
-
#include <gobject/gtype.h>
G_BEGIN_DECLS
/* --- defines --- */
#define G_CLOSURE_NEEDS_MARSHAL(closure) (((GClosure*) (closure))->marshal == NULL)
+#define G_CLOSURE_N_NOTIFIERS(cl) ((cl)->meta_marshal + ((cl)->n_guards << 1L) + \
+ (cl)->n_fnotifiers + (cl)->n_inotifiers)
#define G_CCLOSURE_SWAP_DATA(cclosure) (((GClosure*) (closure))->derivative_flag)
#define G_CALLBACK(f) ((GCallback) (f))
/* -- typedefs --- */
typedef struct _GClosure GClosure;
typedef struct _GClosureNotifyData GClosureNotifyData;
-typedef gpointer GCallback;
+typedef void (*GCallback) (void);
typedef void (*GClosureNotify) (gpointer data,
GClosure *closure);
typedef void (*GClosureMarshal) (GClosure *closure,
/*< private >*/ guint in_inotify : 1;
/*< private >*/ guint floating : 1;
/*< protected >*/ guint derivative_flag : 1;
- /*< puplic >*/ guint in_marshal : 1;
+ /*< public >*/ guint in_marshal : 1;
/*< public >*/ guint is_invalid : 1;
/*< private >*/ void (*marshal) (GClosure *closure,
const GValue *param_values,
gpointer invocation_hint);
-
/* FIXME:
OK: data_object::destroy -> closure_invalidate();
MIS: closure_invalidate() -> disconnect(closure);