~ubuntu-branches/ubuntu/utopic/gridengine/utopic

« back to all changes in this revision

Viewing changes to source/3rdparty/qmon/Xmt310/Xmt/Discard.c

  • Committer: Bazaar Package Importer
  • Author(s): Mark Hymers
  • Date: 2008-06-25 22:36:13 UTC
  • Revision ID: james.westby@ubuntu.com-20080625223613-tvd9xlhuoct9kyhm
Tags: upstream-6.2~beta2
ImportĀ upstreamĀ versionĀ 6.2~beta2

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* 
 
2
 * Motif Tools Library, Version 3.1
 
3
 * $Id$
 
4
 * 
 
5
 * Written by David Flanagan.
 
6
 * Copyright (c) 1992-2001 by David Flanagan.
 
7
 * All Rights Reserved.  See the file COPYRIGHT for details.
 
8
 * This is open source software.  See the file LICENSE for details.
 
9
 * There is no warranty for this software.  See NO_WARRANTY for details.
 
10
 *
 
11
 * $Log$
 
12
 * Revision 1.1.1.1  2001/07/18 11:06:02  root
 
13
 * Initial checkin.
 
14
 *
 
15
 * Revision 1.2  2001/06/12 16:25:28  andre
 
16
 * *** empty log message ***
 
17
 *
 
18
 *
 
19
 */
 
20
 
 
21
#include <Xmt/Xmt.h>
 
22
#include <Xmt/Util.h>
 
23
 
 
24
#if NeedFunctionPrototypes
 
25
void XmtDiscardButtonEvents(Widget w)
 
26
#else
 
27
void XmtDiscardButtonEvents(w)
 
28
Widget w;
 
29
#endif
 
30
{
 
31
    Display *dpy = XtDisplay(w);
 
32
    XEvent event;
 
33
    
 
34
    XSync(dpy, False);  /* get any events from the server */
 
35
    while (XCheckMaskEvent(dpy,
 
36
                           ButtonPressMask | ButtonReleaseMask |
 
37
                           ButtonMotionMask | PointerMotionMask,
 
38
                           &event))
 
39
        ;
 
40
}
 
41
 
 
42
 
 
43
#if NeedFunctionPrototypes
 
44
void XmtDiscardKeyPressEvents(Widget w)
 
45
#else
 
46
void XmtDiscardKeyPressEvents(w)
 
47
Widget w;
 
48
#endif
 
49
{
 
50
    Display *dpy = XtDisplay(w);
 
51
    XEvent event;
 
52
    
 
53
    XSync(dpy, False);  /* get any events from the server */
 
54
    while (XCheckMaskEvent(dpy, KeyPressMask, &event))
 
55
        ;
 
56
}
 
57