Use overload resolution instead of static-call
Sun May 24 16:40:11 CEST 2009 Tobias Rautenkranz <tobias@rautenkranz.ch>
* Use overload resolution instead of static-call
hunk ./src/application.lisp 53
-; (when (typep (app) (find-class 'qt:application))
-; (application.close-all-windows))
+ (when (typep (app) (find-class 'qt:application))
+ (application.close-all-windows))
hunk ./src/application.lisp 60
+ (cxx:delete-later (app))
hunk ./src/package.lisp 3
- (:export #:call
-
- #:app
+ (:export #:app
hunk ./src/qt.lisp 37
-(defun static-call (class-name method-name &rest args)
- (apply #'smoke::static-call *qt-smoke* class-name method-name args))
-
hunk ./src/signal-slot/connect.lisp 153
- (static-call "QMetaObject" "connect#$#$$$"
- sender
- signal-id
- receiver
- slot-id
- (if (null type)
- (value +auto-connection+)
- (value type))
- types))
+ (meta-object.connect sender signal-id
+ receiver slot-id
+ (if (null type)
+ (value +auto-connection+)
+ (value type))
+ types))
hunk ./src/signal-slot/connect.lisp 161
- (static-call "QMetaObject" "disconnect#$#$"
- sender
- signal-id
- receiver
- slot-id))
+ (meta-object.disconnect sender signal-id receiver slot-id))
hunk ./src/signal-slot/signal.lisp 79
- (assert (static-call "QMetaObject" "connect#$#$$$"
- qsignal
- (id qsignal)
- receiver
- slot-id
- type
- ;; QMetaObject::connect is responsible for freeing
- ;; the types array.
- (types (method-arguments-type
- (cxx:meta-object receiver)
- slot-id)))
- ()
- "Failed to connect ~S to the slot ~S of ~S."
- qsignal slot receiver)))
+ (or (meta-object.connect qsignal (id qsignal)
+ receiver slot-id
+ type
+ ;; QMetaObject::connect is responsible [_$_]
+ ;; for freeing the types array.
+ (types (method-arguments-type
+ (cxx:meta-object receiver)
+ slot-id)))
+ (cerror "Ignore"
+ "Failed to connect ~S to the slot ~S of ~S."
+ qsignal slot receiver))))
hunk ./src/signal-slot/signal.lisp 94
- (cxx:data
- (meta-object.normalized-signature slot)))))
+ (cxx:data
+ (meta-object.normalized-signature slot)))))
hunk ./src/signal-slot/signal.lisp 100
- (assert (static-call "QMetaObject" "disconnect#$#$"
- qsignal
- (id qsignal)
- receiver
- slot-id)
- ()
- "Failed to disconnect ~S to the slot ~S of ~S."
- qsignal slot receiver)))
+ (or (meta-object.disconnect qsignal (id qsignal)
+ receiver slot-id)
+ (cerror "Ignore" [_$_]
+ "Failed to disconnect ~S to the slot ~S of ~S."
+ qsignal slot receiver))))
hunk ./src/signal-slot/signal.lisp 144
- (smoke::static-call *qt-smoke* "QMetaObject" "activate##$?"
- qsignal
- (cxx:meta-object qsignal)
+ (meta-object.activate qsignal (cxx:meta-object qsignal)
hunk ./src/signal-slot/slot.lisp 73
- (let ((ret (static-call "QMetaObject" "connect#$#$$$"
- sender
- signal-id
- slot
- (id slot)
- type
- (types (arguments slot)))))
+ (let ((ret (meta-object.connect sender signal-id
+ slot (id slot)
+ type (types (arguments slot)))))
hunk ./src/signal-slot/slot.lisp 77
- (cxx:connect-notify sender signal)
- (cerror "Failed to connect the signal ~S of ~S to the function ~S."
- signal sender function)))))
+ (cxx:connect-notify sender signal)
+ (cerror "Failed to connect the signal ~S of ~S to the function ~S."
+ signal sender function)))))