2 * CDE - Common Desktop Environment
4 * Copyright (c) 1993-2012, The Open Group. All rights reserved.
6 * These libraries and programs are free software; you can
7 * redistribute them and/or modify them under the terms of the GNU
8 * Lesser General Public License as published by the Free Software
9 * Foundation; either version 2 of the License, or (at your option)
12 * These libraries and programs are distributed in the hope that
13 * they will be useful, but WITHOUT ANY WARRANTY; without even the
14 * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 * PURPOSE. See the GNU Lesser General Public License for more
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with these librararies and programs; if not, write
20 * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
21 * Floor, Boston, MA 02110-1301 USA
24 * (c) Copyright 1989, 1990, 1991, 1992 OPEN SOFTWARE FOUNDATION, INC.
30 /* $XConsortium: WmEvent.h /main/5 1996/06/11 15:59:25 rswiston $ */
32 * (c) Copyright 1987, 1988, 1989, 1990 HEWLETT-PACKARD COMPANY */
35 /* Shared Variables */
36 extern int smAckState;
40 extern Boolean CheckForButtonAction (XButtonEvent *buttonEvent,
41 Context context, Context subContext,
43 extern Time GetTimestamp (void);
44 #if ((!defined(WSM)) || defined(MWM_QATS_PROTOCOL))
45 extern Time LastTime (void);
46 #endif /* !defined(WSM) || defined(MWM_QATS_PROTOCOL) */
47 extern Boolean HandleKeyPress (XKeyEvent *keyEvent, KeySpec *keySpecs,
48 Boolean checkContext, Context context,
49 Boolean onlyFirst, ClientData *pCD);
50 extern void HandleWsButtonPress (XButtonEvent *buttonEvent);
51 extern void HandleWsButtonRelease (XButtonEvent *buttonEvent);
52 extern void HandleWsConfigureRequest (XConfigureRequestEvent *configureEvent);
53 extern void HandleWsEnterNotify (XEnterWindowEvent *enterEvent);
54 extern void HandleWsFocusIn (XFocusInEvent *focusEvent);
55 extern Boolean HandleWsKeyPress (XKeyEvent *keyEvent);
56 extern void HandleWsLeaveNotify (XLeaveWindowEvent *leaveEvent);
57 extern void IdentifyEventContext (XButtonEvent *event, ClientData *pCD,
58 Context *pContext, int *pPartContext);
59 extern void InitEventHandling (void);
60 extern void ProcessClickBPress (XButtonEvent *buttonEvent, ClientData *pCD,
61 Context context, Context subContext);
62 extern void ProcessClickBRelease (XButtonEvent *buttonEvent, ClientData *pCD,
63 Context context, Context subContext);
64 extern void PullExposureEvents (void);
65 extern int SetupKeyBindings (KeySpec *keySpecs, Window grabWindow,
66 int keyboardMode, long context);
67 extern Boolean WmDispatchMenuEvent (XButtonEvent *event);
68 extern Boolean WmDispatchWsEvent (XEvent *event);
69 extern void WmGrabButton (Display *display, unsigned int button,
70 unsigned int modifiers, Window grab_window,
71 unsigned int event_mask, Bool owner_events, int pointer_mode,
72 int keyboard_mode, Window confine_to, Cursor cursor);
73 extern void WmGrabKey (Display *display, int keycode, unsigned int modifiers,
74 Window grab_window, Bool owner_events, int pointer_mode,
76 extern void WmUngrabButton (Display *display, unsigned int button,
77 unsigned int modifiers, Window grab_window);
79 extern void HandleDtWmClientMessage (XClientMessageEvent *clientEvent);
80 extern void HandleDtWmRequest (WmScreenData *pSD, XEvent *pev);
81 extern Boolean ReplayedButtonEvent (XButtonEvent *pevB1, XButtonEvent *pevB2);