chiark
/
gitweb
/
~mdw
/
clg
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Minor code cleanup
[clg]
/
glib
/
gobject.lisp
diff --git
a/glib/gobject.lisp
b/glib/gobject.lisp
index 115a04ca75cfee7063c39a822c9eca918ac52c67..6543d2df109ca4de59a1a565e55a0ad3e6535def 100644
(file)
--- a/
glib/gobject.lisp
+++ b/
glib/gobject.lisp
@@
-20,7
+20,7
@@
;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-;; $Id: gobject.lisp,v 1.5
4 2006-08-16 12:09:03
espen Exp $
+;; $Id: gobject.lisp,v 1.5
6 2007-05-10 20:25:30
espen Exp $
(in-package "GLIB")
(in-package "GLIB")
@@
-154,7
+154,7
@@
(defmethod compute-slot-reader-function ((slotd effective-property-slot-definiti
(defmethod compute-slot-writer-function :around ((slotd effective-property-slot-definition))
(if (construct-only-property-p slotd)
#'(lambda (value object)
(defmethod compute-slot-writer-function :around ((slotd effective-property-slot-definition))
(if (construct-only-property-p slotd)
#'(lambda (value object)
- (declare (ignore value
object
))
+ (declare (ignore value))
(unless *ignore-setting-construct-only-property*
(error 'unwritable-slot :name (slot-definition-name slotd) :instance object)))
(call-next-method)))
(unless *ignore-setting-construct-only-property*
(error 'unwritable-slot :name (slot-definition-name slotd) :instance object)))
(call-next-method)))
@@
-391,35
+391,40
@@
(defbinding object-thaw-notify () nil
;;;; User data
;;;; User data
+(defgeneric (setf user-data) (data object key))
+(defgeneric user-data (object key))
+(defgeneric user-data-p (object key))
+(defgeneric unset-user-data (object key))
+
(defbinding %object-set-qdata-full () nil
(object gobject)
(id quark)
(defbinding %object-set-qdata-full () nil
(object gobject)
(id quark)
- (data
unsigned-long
)
+ (data
pointer-data
)
(destroy-marshal callback))
(destroy-marshal callback))
-(define-callback user-data-destroy-callback nil ((id
unsigned-int
))
+(define-callback user-data-destroy-callback nil ((id
pointer-data
))
(destroy-user-data id))
(destroy-user-data id))
-(def
un (setf user-data) (data object
key)
+(def
method (setf user-data) (data (object gobject)
key)
(%object-set-qdata-full object (quark-intern key)
(register-user-data data) user-data-destroy-callback)
data)
(%object-set-qdata-full object (quark-intern key)
(register-user-data data) user-data-destroy-callback)
data)
-(defbinding %object-get-qdata ()
unsigned-long
+(defbinding %object-get-qdata ()
pointer-data
(object gobject)
(id quark))
(object gobject)
(id quark))
-(def
un user-data (object
key)
+(def
method user-data ((object gobject)
key)
(find-user-data (%object-get-qdata object (quark-intern key))))
(find-user-data (%object-get-qdata object (quark-intern key))))
-(def
un user-data-p (object
key)
+(def
method user-data-p ((object gobject)
key)
(user-data-exists-p (%object-get-qdata object (quark-intern key))))
(user-data-exists-p (%object-get-qdata object (quark-intern key))))
-(defbinding %object-steal-qdata ()
unsigned-long
+(defbinding %object-steal-qdata ()
pointer-data
(object gobject)
(id quark))
(object gobject)
(id quark))
-(def
un unset-user-data (object
key)
+(def
method unset-user-data ((object gobject)
key)
(destroy-user-data (%object-steal-qdata object (quark-intern key))))
(destroy-user-data (%object-steal-qdata object (quark-intern key))))