summaryrefslogtreecommitdiff
path: root/gdk-pixbuf/gdk-pixbuf-private.h
diff options
context:
space:
mode:
authorHavoc Pennington <hp@pobox.com>2000-06-22 15:36:12 +0000
committerHavoc Pennington <hp@src.gnome.org>2000-06-22 15:36:12 +0000
commit08f90167233bdbf73ed9b75fe7b0705912424c0d (patch)
tree3db49d51c16d0b64691cf68ebcf77f5cc611d7de /gdk-pixbuf/gdk-pixbuf-private.h
parent3977f42fd446e0234459056518676d94cde7e8d0 (diff)
downloadgdk-pixbuf-08f90167233bdbf73ed9b75fe7b0705912424c0d.tar.gz
Convert GdkPixbuf to GObject, leaving it opaque (i.e. derivation is not
2000-06-21 Havoc Pennington <hp@pobox.com> * gdk-pixbuf.c: Convert GdkPixbuf to GObject, leaving it opaque (i.e. derivation is not allowed, and there are no virtual methods anyway). (gdk_pixbuf_preinit): Call g_type_init() here. (gdk_pixbuf_init): Add a user-friendly init function, for users of standalone gdk-pixbuf * gdk-pixbuf-animation.c: Convert to GObject, in the same way GdkPixbufAnimation was done. * gdk-pixbuf.h: Remove gdk_pixbuf_set_unref_handler() and gdk_pixbuf_finalize() from API, since these are broken and don't make sense with new GObject stuff. 2000-06-21 Havoc Pennington <hp@pobox.com> * gdk/gdkwindow.c (_gdk_window_destroy_hierarchy): Fix bug where we didn't check window->bg_pixmap != GDK_NO_BG. * gtk/gdk-pixbuf-loader.c: Change to reflect GObject-ification of gdk-pixbuf
Diffstat (limited to 'gdk-pixbuf/gdk-pixbuf-private.h')
-rw-r--r--gdk-pixbuf/gdk-pixbuf-private.h35
1 files changed, 25 insertions, 10 deletions
diff --git a/gdk-pixbuf/gdk-pixbuf-private.h b/gdk-pixbuf/gdk-pixbuf-private.h
index 4595785a0..2aecb6623 100644
--- a/gdk-pixbuf/gdk-pixbuf-private.h
+++ b/gdk-pixbuf/gdk-pixbuf-private.h
@@ -30,10 +30,15 @@
+typedef struct _GdkPixbufClass GdkPixbufClass;
+
+#define GDK_PIXBUF_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GDK_TYPE_PIXBUF, GdkPixbufClass))
+#define GDK_IS_PIXBUF_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GDK_TYPE_PIXBUF))
+#define GDK_PIXBUF_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GDK_TYPE_PIXBUF, GdkPixbufClass))
+
/* Private part of the GdkPixbuf structure */
struct _GdkPixbuf {
- /* Reference count */
- int ref_count;
+ GObject parent_instance;
/* Color space */
GdkColorspace colorspace;
@@ -59,16 +64,15 @@ struct _GdkPixbuf {
/* User data for the destroy notification function */
gpointer destroy_fn_data;
- /* Last unref handler, determines whether the pixbuf should be finalized */
- GdkPixbufLastUnref last_unref_fn;
-
- /* User data for the last unref handler */
- gpointer last_unref_fn_data;
-
/* Do we have an alpha channel? */
guint has_alpha : 1;
};
+struct _GdkPixbufClass {
+ GObjectClass parent_class;
+
+};
+
/* Private part of the GdkPixbufFrame structure */
struct _GdkPixbufFrame {
/* The pixbuf with this frame's image data */
@@ -85,10 +89,15 @@ struct _GdkPixbufFrame {
GdkPixbufFrameAction action;
};
+typedef struct _GdkPixbufAnimationClass GdkPixbufAnimationClass;
+
+#define GDK_PIXBUF_ANIMATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GDK_TYPE_PIXBUF_ANIMATION, GdkPixbufAnimationClass))
+#define GDK_IS_PIXBUF_ANIMATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GDK_TYPE_PIXBUF_ANIMATION))
+#define GDK_PIXBUF_ANIMATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GDK_TYPE_PIXBUF_ANIMATION, GdkPixbufAnimationClass))
+
/* Private part of the GdkPixbufAnimation structure */
struct _GdkPixbufAnimation {
- /* Reference count */
- int ref_count;
+ GObject parent_instance;
/* Number of frames */
int n_frames;
@@ -100,6 +109,12 @@ struct _GdkPixbufAnimation {
int width, height;
};
+struct _GdkPixbufAnimationClass {
+ GObjectClass parent_class;
+
+
+};
+
#endif