From 60c1f92549b90d0fdc6ce4e069ed0e25d0fa9689 Mon Sep 17 00:00:00 2001 From: Marco Pesenti Gritti Date: Thu, 13 Jan 2005 09:33:09 +0000 Subject: [PATCH] *** empty log message *** --- pixbuf/pixbuf-document.c | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/pixbuf/pixbuf-document.c b/pixbuf/pixbuf-document.c index 01df2783..843df3d2 100644 --- a/pixbuf/pixbuf-document.c +++ b/pixbuf/pixbuf-document.c @@ -20,6 +20,11 @@ #include "pixbuf-document.h" #include "ev-document-thumbnails.h" +enum { + PROP_0, + PROP_TITLE +}; + struct _PixbufDocumentClass { GObjectClass parent_class; @@ -185,6 +190,34 @@ pixbuf_document_finalize (GObject *object) G_OBJECT_CLASS (parent_class)->finalize (object); } +static void +pixbuf_document_set_property (GObject *object, + guint prop_id, + const GValue *value, + GParamSpec *pspec) +{ + switch (prop_id) + { + case PROP_TITLE: + /* read only */ + break; + } +} + +static void +pixbuf_document_get_property (GObject *object, + guint prop_id, + GValue *value, + GParamSpec *pspec) +{ + switch (prop_id) + { + case PROP_TITLE: + g_value_set_string (value, NULL); + break; + } +} + static void pixbuf_document_class_init (PixbufDocumentClass *klass) { @@ -193,6 +226,10 @@ pixbuf_document_class_init (PixbufDocumentClass *klass) parent_class = g_type_class_peek_parent (klass); gobject_class->finalize = pixbuf_document_finalize; + gobject_class->get_property = pixbuf_document_get_property; + gobject_class->set_property = pixbuf_document_set_property; + + g_object_class_override_property (gobject_class, PROP_TITLE, "title"); } static void -- 2.43.5