diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/application.lisp | 8 | ||||
-rw-r--r-- | src/events/event-handler.lisp | 3 | ||||
-rw-r--r-- | src/events/listener.lisp | 6 | ||||
-rw-r--r-- | src/package.lisp | 6 |
4 files changed, 5 insertions, 18 deletions
diff --git a/src/application.lisp b/src/application.lisp index 4073a15..5b6e9ad 100644 --- a/src/application.lisp +++ b/src/application.lisp @@ -71,22 +71,20 @@ (focus (when (slot-boundp app 'focus) (unless (eq new-value (slot-value app 'focus)) - (fire-blur-event-on (slot-value app 'focus))))))) + (fire-blur-event-on (slot-value app 'focus)) + (fire-focus-event-on new-value)))))) (defmethod (setf closer-mop:slot-value-using-class) :after (new-value class (app application) slot) (case (closer-mop:slot-definition-name slot) ((scale width height) (set-projection app)) - (focus - (fire-focus-event-on new-value)) (fps (setf (slot-value app 'frame-wait) (/ 1.0 new-value))))) (defparameter +listener-table-slot-names+ '(keydown-table keyup-table mousedown-table mouseup-table mousemotion-table - focus-table blur-table perframe-table after-added-table before-added-table - before-dropped-table)) + focus-table blur-table perframe-table)) (defmethod cleanup ((app application)) (loop for asset being the hash-value of (application-assets app) diff --git a/src/events/event-handler.lisp b/src/events/event-handler.lisp index a88f63d..e9a26cd 100644 --- a/src/events/event-handler.lisp +++ b/src/events/event-handler.lisp @@ -262,6 +262,7 @@ can be redefined using this form to support interactive development." " `(make-instance 'event-handler + :tag ,(get-tag-from-handler-body body) :event-type 'wheelwork::mousewheel :handler-function (lambda (,(intern (symbol-name target)) @@ -273,7 +274,7 @@ can be redefined using this form to support interactive development." ,(intern (symbol-name horiz)) ,(intern (symbol-name vert)) ,(intern (symbol-name dir)))) - ,@body))) + ,@(get-body-from-handler-body body)))) (defmacro on-blur ((&optional (target 'target)) &body body) diff --git a/src/events/listener.lisp b/src/events/listener.lisp index 366465a..e66afe2 100644 --- a/src/events/listener.lisp +++ b/src/events/listener.lisp @@ -12,9 +12,6 @@ focus blur perframe - after-added - before-added - before-dropped :r :with :type (or null event-handler) :std nil) (keydown-table keyup-table @@ -25,9 +22,6 @@ focus-table blur-table perframe-table - after-added-table - before-added-table - before-dropped-table :static :std (make-hash-table :synchronized t) :doc "Keyed by DISPLAY-UNIT instance, holds an EVENT-HANDLER if diff --git a/src/package.lisp b/src/package.lisp index 7a07726..22cb797 100644 --- a/src/package.lisp +++ b/src/package.lisp @@ -47,9 +47,6 @@ ;; Event Handler API #:add-handler #:defhandler - #:on-after-added - #:on-before-added - #:on-before-dropped #:on-blur #:on-focus #:on-keydown @@ -62,9 +59,6 @@ ;; Event Names, useful for dropping whole classes of events from a ;; unit - #:after-added - #:before-added - #:before-dropped #:blur #:focus #:keydown |