InterViews Reference Manual -- Sensor
NAME
Sensor - input interest for interactors
SYNOPSIS
#include <InterViews/sensor.h>
DESCRIPTION
A sensor specifies a set of interesting input events. Several sensors are
predefined as global variables. The sensor ``allEvents'' is interested in all
user input events (excludes ChannelEvent and TimerEvent); ``noEvents'' is not
interested in any events; ``updownEvents'' is interested in UpEvents and
DownEvents; and ``onoffEvents'' is interested in EnterEvents and LeaveEvents.
PUBLIC OPERATIONS
Sensor()
Create a new sensor that is not interested in any events.
Sensor(Sensor*)
Create a sensor whose interests are the same as the given sensor.
void Catch(EventType)
void CatchButton(EventType,
int)
void CatchChannel(int)
void
CatchTimer(int sec, int usec)
Express interest in an event. CatchButton can be used for keys as well as
buttons, though it is necessary to know the key code. Not all types of events
make sense for all the operations; for example, Catch(ChannelEvent) is not
meaningful. Such requests are silently ignored.
void Ignore(EventType)
void
IgnoreButton(EventType, int)
void
IgnoreChannel(int)
Remove interest in an event. Ignore means no interest in any events of a
particular kind; thus Ignore(DownEvent) means pressing any button will not
generate an event.
void CatchRemote()
void IgnoreRemote()
Express or remove interest in access to the structure of an interactor's
canvas. Only a world view should use these operations, as such access is
reported using the WorldView::InsertRemote and WorldView::ChangeRemote
operations.
SEE ALSO
Interactor , World , WorldView
Next: Shape
| Prev: Scroller
| Up: index
| Top: index