10bbfda8aSnia/*
20bbfda8aSnia * twm event handler include file
3645f5050Syouri *
4645f5050Syouri *
50bbfda8aSnia *       Copyright 1988 by Evans & Sutherland Computer Corporation,
60bbfda8aSnia *                          Salt Lake City, Utah
70bbfda8aSnia *  Portions Copyright 1989 by the Massachusetts Institute of Technology
80bbfda8aSnia *                        Cambridge, Massachusetts
9645f5050Syouri *
10645f5050Syouri * $XConsortium: events.h,v 1.14 91/05/10 17:53:58 dave Exp $
11645f5050Syouri *
120bbfda8aSnia * 17-Nov-87 Thomas E. LaStrange                File created
13645f5050Syouri *
140bbfda8aSnia * Copyright 1992 Claude Lecommandeur.
15645f5050Syouri *
160bbfda8aSnia */
17645f5050Syouri
180bbfda8aSnia#ifndef _CTWM_EVENTS_H
190bbfda8aSnia#define _CTWM_EVENTS_H
20645f5050Syouri
21645f5050Syouritypedef void (*event_proc)(void);
22645f5050Syouri
230bbfda8aSniavoid InitEvents(void);
240bbfda8aSniabool DispatchEvent(void);
250bbfda8aSniabool DispatchEvent2(void);
260bbfda8aSniavoid HandleEvents(void) __attribute__((noreturn));
27645f5050Syouri
280bbfda8aSnia/* Bits in event_utils.c */
290bbfda8aSnia/*
300bbfda8aSnia * This should maybe be in event_internal.h, but a few other places use
310bbfda8aSnia * it.  TBD: figure out why and whether they should
320bbfda8aSnia */
330bbfda8aSniavoid AutoRaiseWindow(TwmWindow *tmp);
34645f5050Syouri
350bbfda8aSniavoid FixRootEvent(XEvent *e);
360bbfda8aSniavoid SimulateMapRequest(Window w);
37645f5050Syouri
38645f5050Syouri
39645f5050Syouriextern event_proc EventHandler[];
40645f5050Syouriextern Window DragWindow;
41645f5050Syouriextern int origDragX;
42645f5050Syouriextern int origDragY;
43645f5050Syouriextern int DragX;
44645f5050Syouriextern int DragY;
45645f5050Syouriextern unsigned int DragWidth;
46645f5050Syouriextern unsigned int DragHeight;
47645f5050Syouriextern unsigned int DragBW;
48645f5050Syouriextern int CurrentDragX;
49645f5050Syouriextern int CurrentDragY;
500bbfda8aSniaextern int Context;
51645f5050Syouri
52645f5050Syouriextern int ButtonPressed;
530bbfda8aSniaextern bool Cancel;
54645f5050Syouri
55645f5050Syouriextern XEvent Event;
560bbfda8aSniaextern Time EventTime;
57645f5050Syouri
580bbfda8aSnia#endif /* _CTWM_EVENTS_H */
59