2020-09-29 10:56 UTC
Guys Hi,
in order to suppress the event handlers from popping in command history i thought this:
say i have awf.lsp. the (c:awf) function will only load it self and the main function to control the dialog box
wrapped in (apply '(lambda () ....) '()) - see the example
at the end set to nil all the event handlers
does this make sense?
(consider the load time of standard lisp file is less than a second)
Moshe
in order to suppress the event handlers from popping in command history i thought this:
say i have awf.lsp. the (c:awf) function will only load it self and the main function to control the dialog box
wrapped in (apply '(lambda () ....) '()) - see the example
at the end set to nil all the event handlers
does this make sense?
(consider the load time of standard lisp file is less than a second)
Moshe
(vl-load-com)
(defun c:awf ()
(prompt "\nLoading awf.lsp...")
(load "awf")
)
; execute at load time
; control the dialog box
(apply
'(lambda (/ whatnext)
(command "OPENDCL")
(dcl_Project_Load "awf")
(setq whatnext 10)
(while (> whatnext 2)
(dcl_Form_Show "awf/Form1")
)
; remove handlers
(foreach func (list 'c:event/handler1 'c:event/handler2 'c:event/handler3)
(set func nil)
)
(princ)
); lambda
'()
); apply
(defun c:event/handler1 ()
; func code
; ...
)
(defun c:event/handler2 ()
; func code
; ...
)
(defun c:event/handler3 ()
; func code
; ...
)