From 8a51ba81c7df6b0b6dab7cf4b35b5ca084b653ba Mon Sep 17 00:00:00 2001 From: colin Date: Tue, 10 Dec 2024 07:11:02 -0800 Subject: Replaced defclass-std with def --- src/events/event-handler.lisp | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'src/events/event-handler.lisp') diff --git a/src/events/event-handler.lisp b/src/events/event-handler.lisp index e9a26cd..62d8f54 100644 --- a/src/events/event-handler.lisp +++ b/src/events/event-handler.lisp @@ -2,10 +2,15 @@ (in-package #:wheelwork) - -(defclass/std event-handler () - ((event-type handler-function tag :ri)) - (:metaclass closer-mop:funcallable-standard-class)) +;; TODO: make event-type a type +(def:class event-handler () + ((event-type "A symbol naming the sort of event this function handles") + :required :ro) + ((tag "A tag identifying this handler uniquely. Used to remove anonymous handlers") + :ro :type (or null string) :initform nil) + ((handler-function "The actual function this handler calls") + :required :ro :type function) + :metaclass closer-mop:funcallable-standard-class) (defmethod initialize-instance :after ((eh event-handler) &key) (with-slots (handler-function) eh -- cgit v1.2.3