From 867703d82c6e8b7a2b424845fcb30537061de45a Mon Sep 17 00:00:00 2001 From: Colin Okay Date: Fri, 1 Jul 2022 09:47:16 -0500 Subject: [add] frameset class and an [exmaple] using it --- src/interactive/button.lisp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/interactive/button.lisp') diff --git a/src/interactive/button.lisp b/src/interactive/button.lisp index 1c546ba..a885ef0 100644 --- a/src/interactive/button.lisp +++ b/src/interactive/button.lisp @@ -27,6 +27,12 @@ (when on-press (funcall on-press target))))) +(defmethod (setf closer-mop:slot-value-using-class) :before + (newval class (button button) slot) + (case (closer-mop:slot-definition-name slot) + ((up down bg) + (error "Swapping Button Faces Not Presently Supported")))) + (defmethod initialize-instance :after ((button button) &key) (add-handler button #'button-pressed) (add-handler button #'button-released) @@ -123,8 +129,6 @@ (setf (height up) newval (height down) newval))) - - (defun make-texture-button (up down &key pressed released) "UP and DOWN should be strings naming assets to use as the up and down images for the button." -- cgit v1.2.3