/* $Id: evtomask.c,v 1.1.1.1 90/11/28 17:02:06 altenhof Exp $ */

/*
 * Copyright (C) 1990 by Digital Equipment Corporation.
 * 
 * Author: Michael P. Altenhofen, CEC Karlsruhe e-mail:
 * Altenhofen@kampus.enet.dec.com
 * 
 * This file ist part of Shared X
 * 
 * Permission to use, copy, modify, and distribute this software and its
 * documentation without fee is hereby granted, but only for non-profit  use
 * and distribution,  and provided  that the copyright notice and this notice
 * is preserved on all copies.
 * 
 * DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
 * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
 * DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
 * ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
 * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
 * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
 * SOFTWARE.
 */
#include "X.h"

/*
 * This array can be used given an event type to determine the mask bits that
 * could have generated it.
 */
long _event_to_mask[LASTEvent] =
{
  0,				/* no event 0 */
  0,				/* no event 1 */
  KeyPressMask,			/* KeyPress */
  KeyReleaseMask,		/* KeyRelease */
  ButtonPressMask,		/* ButtonPress */
  ButtonReleaseMask,		/* ButtonRelease */
  PointerMotionMask | PointerMotionHintMask | Button1MotionMask |
  Button2MotionMask | Button3MotionMask | Button4MotionMask |
  Button5MotionMask | ButtonMotionMask,	/* MotionNotify */
  EnterWindowMask,		/* EnterNotify */
  LeaveWindowMask,		/* LeaveNotify */
  FocusChangeMask,		/* FocusIn */
  FocusChangeMask,		/* FocusOut */
  KeymapStateMask,		/* KeymapNotify */
  ExposureMask,			/* Expose */
  ExposureMask,			/* GraphicsExpose */
  ExposureMask,			/* NoExpose */
  VisibilityChangeMask,		/* VisibilityNotify */
  SubstructureNotifyMask,	/* CreateNotify */
  StructureNotifyMask | SubstructureNotifyMask,	/* DestroyNotify */
  StructureNotifyMask | SubstructureNotifyMask,	/* UnmapNotify */
  StructureNotifyMask | SubstructureNotifyMask,	/* MapNotify */
  SubstructureRedirectMask,	/* MapRequest */
  SubstructureNotifyMask | StructureNotifyMask,	/* ReparentNotify */
  StructureNotifyMask | SubstructureNotifyMask,	/* ConfigureNotify */
  SubstructureRedirectMask,	/* ConfigureRequest */
  SubstructureNotifyMask | StructureNotifyMask,	/* GravityNotify */
  ResizeRedirectMask,		/* ResizeRequest */
  SubstructureNotifyMask | StructureNotifyMask,	/* CirculateNotify */
  SubstructureRedirectMask,	/* CirculateRequest */
  PropertyChangeMask,		/* PropertyNotify */
  0,				/* SelectionClear */
  0,				/* SelectionRequest */
  0,				/* SelectionNotify */
  ColormapChangeMask,		/* ColormapNotify */
  0				/* InterpretNotify */
};
