123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149 |
- #ifndef __G_BINDING_H__
- #define __G_BINDING_H__
- #if !defined (__GLIB_GOBJECT_H_INSIDE__) && !defined (GOBJECT_COMPILATION)
- #error "Only <glib-object.h> can be included directly."
- #endif
- #include <glib.h>
- #include <gobject/gobject.h>
- G_BEGIN_DECLS
- #define G_TYPE_BINDING_FLAGS (g_binding_flags_get_type ())
- #define G_TYPE_BINDING (g_binding_get_type ())
- #define G_BINDING(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), G_TYPE_BINDING, GBinding))
- #define G_IS_BINDING(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), G_TYPE_BINDING))
- typedef struct _GBinding GBinding;
- typedef gboolean (* GBindingTransformFunc) (GBinding *binding,
- const GValue *from_value,
- GValue *to_value,
- gpointer user_data);
- typedef enum {
- G_BINDING_DEFAULT = 0,
- G_BINDING_BIDIRECTIONAL = 1 << 0,
- G_BINDING_SYNC_CREATE = 1 << 1,
- G_BINDING_INVERT_BOOLEAN = 1 << 2
- } GBindingFlags;
- GLIB_AVAILABLE_IN_ALL
- GType g_binding_flags_get_type (void) G_GNUC_CONST;
- GLIB_AVAILABLE_IN_ALL
- GType g_binding_get_type (void) G_GNUC_CONST;
- GLIB_AVAILABLE_IN_ALL
- GBindingFlags g_binding_get_flags (GBinding *binding);
- GLIB_AVAILABLE_IN_ALL
- GObject * g_binding_get_source (GBinding *binding);
- GLIB_AVAILABLE_IN_ALL
- GObject * g_binding_get_target (GBinding *binding);
- GLIB_AVAILABLE_IN_ALL
- const gchar * g_binding_get_source_property (GBinding *binding);
- GLIB_AVAILABLE_IN_ALL
- const gchar * g_binding_get_target_property (GBinding *binding);
- GLIB_AVAILABLE_IN_2_38
- void g_binding_unbind (GBinding *binding);
- GLIB_AVAILABLE_IN_ALL
- GBinding *g_object_bind_property (gpointer source,
- const gchar *source_property,
- gpointer target,
- const gchar *target_property,
- GBindingFlags flags);
- GLIB_AVAILABLE_IN_ALL
- GBinding *g_object_bind_property_full (gpointer source,
- const gchar *source_property,
- gpointer target,
- const gchar *target_property,
- GBindingFlags flags,
- GBindingTransformFunc transform_to,
- GBindingTransformFunc transform_from,
- gpointer user_data,
- GDestroyNotify notify);
- GLIB_AVAILABLE_IN_ALL
- GBinding *g_object_bind_property_with_closures (gpointer source,
- const gchar *source_property,
- gpointer target,
- const gchar *target_property,
- GBindingFlags flags,
- GClosure *transform_to,
- GClosure *transform_from);
- G_END_DECLS
- #endif
|