[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

event handling

I designed a sample program for event handling as follows:

(defcalss my-window (window)())

(defmethod view-click-event-handler
          ((window my-window) position) )

(make-instance 'my-window
              (make-dialog-item 'button-dialog-item
               #@(100 20)
               #@(50 25 ) "OK"
               #'(lambda (item)
                (print "OK")))))

I click the button, but it does not work.  After I remove the
view-click-event-handler, it works.  Is that true all the dialog items
will not work if we use event handlers?

I would like to design the user interface that will contain different
views, including buttons, table item, pop-up menu, editable text and
"sub-window" for pictures.  Must we be based on the position of cursor
to dispatch actions?