-(defmethod initialize-internal-slot-functions ((slotd effective-child-slot-definition))
- (let ((type (slot-definition-type slotd))
- (pname (slot-definition-pname slotd)))
- (setf
- (slot-value slotd 'getter)
- #'(lambda (object)
- (with-slots (parent child) object
- (let ((gvalue (gvalue-new type)))
- (%container-child-get-property parent child pname gvalue)
- (unwind-protect
- (funcall (reader-function type) gvalue +gvalue-value-offset+)
- (gvalue-free gvalue t))))))
-
- (setf
- (slot-value slotd 'setter)
- #'(lambda (value object)
- (with-slots (parent child) object
- (let ((gvalue (gvalue-new type)))
- (funcall (writer-function type) value gvalue +gvalue-value-offset+)
- (%container-child-set-property parent child pname gvalue)
- (gvalue-free gvalue t)
- value)))))
-
- (call-next-method)))
-
+(defmethod compute-slot-reader-function ((slotd effective-child-slot-definition) &optional signal-unbound-p)
+ (declare (ignore signal-unbound-p))
+ (let* ((type (slot-definition-type slotd))
+ (pname (slot-definition-pname slotd))
+ (reader (reader-function type :ref :get)))
+ #'(lambda (object)
+ (with-slots (parent child) object
+ (with-memory (gvalue +gvalue-size+)
+ (glib::%gvalue-init gvalue (find-type-number type))
+ (%container-child-get-property parent child pname gvalue)
+ (funcall reader gvalue +gvalue-value-offset+))))))
+
+(defmethod slot-writable-p ((slotd effective-child-slot-definition))
+ (declare (ignore slotd))
+ t)