2
; dispatch-events.lsp Hiep Huu Nguyen 27 Aug 92
4
; Copyright (c) 1994 Hiep Huu Nguyen and The University of Texas at Austin.
6
; See the files gnu.license and dec.copyright .
8
; This program is free software; you can redistribute it and/or modify
9
; it under the terms of the GNU General Public License as published by
10
; the Free Software Foundation; either version 1, or (at your option)
13
; This program is distributed in the hope that it will be useful,
14
; but WITHOUT ANY WARRANTY; without even the implied warranty of
15
; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
; GNU General Public License for more details.
18
; You should have received a copy of the GNU General Public License
19
; along with this program; if not, write to the Free Software
20
; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
22
; Some of the files that interface to the Xlib are adapted from DEC/MIT files.
23
; See the file dec.copyright for details.
26
;;have to make each type have it's own eventlist
28
(defun dispatch-events ()
37
(dolist (a-display *display-list*)
38
(unless (= (XPending a-display) 0)
39
(XNextEvent a-display *default-event*)
40
(setq type (XAnyEvent-type *default-event*))
42
(gethash (XAnyEvent-window *default-event*)
45
(rest (assoc type (slot-value window 'eventlist))))
47
(dolist (call-back-fn call-back-fns)
48
(eval `(,call-back-fn ',window))))))))