Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
XmtDiscardButtonEvents(3)  Library Functions Manual  XmtDiscardButtonEvents(3)

NAME
       XmtDiscardButtonEvents(),  XmtDiscardKeyPressEvents() - discard pending
       user input events.

SYNOPSIS
       #include	<Xmt/Xmt.h>

       void XmtDiscardButtonEvents(Widget w)

       void XmtDiscardKeyPressEvents(Widget w)

ARGUMENTS
       INPUTS

	    w	   Any widget on the display for which events are to  be  dis-
		   carded.

DESCRIPTION
       XmtDiscardButtonEvents()	gets all pending events	from the X server, and
       then  removes all ButtonPress, ButtonRelease, ButtonMotion and Pointer-
       Motion events from the Xlib event queue,	without	 processing  them.  It
       affects	events	generated in any window	of the application on the same
       display as w.

       XmtDiscardKeyPressEvents() removes all pending KeyPress events  in  the
       same  way. This function	does not remove	Key Release events, because it
       may be called from callback or action procedures	triggered  (through  a
       translation  table)  by KeyPress	events,	and the	Xt Translation Manager
       expects to see the corresponding	KeyRelease events in order  to	return
       to  its	default	 state.	 Calling  this	function may leave a series of
       KeyRelease events on the	queue, but these will generally	will not trig-
       ger any translations.

       XmtDiscardButtonEvents()	can be used to prevent ``click ahead'' buffer-
       ing of mouse events while an application	is doing any lengthy  computa-
       tion  or	I/O without servicing events. Similarly, XmtDiscardKeyPressEv-
       ents() can be used to prevent ``type-ahead''. If	you will be discarding
       events, you should be sure to provide feedback to  the  user  that  the
       events will not be processed-display a ``please wait'' cursor or	dialog
       box. See	XmtDisplayBusyCursor() and Xmt DisplayWorkingDialog().

SEE ALSO
       Chapter 31, Busy	States and Background Work, XmtDisplayBusyCursor(),
       XmtDisplayWorkingDialog().

Xmt				  Motif	Tools	     XmtDiscardButtonEvents(3)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=XmtDiscardKeyPressEvents&sektion=3&manpath=FreeBSD+Ports+15.0>

home | help