Main Page   Modules   Class Hierarchy   Compound List   Compound Members  

GAUGE3D::GInputMessage Class Reference

Represents an input message. More...

#include <gauge3d/input/message.h>

Inherits GAUGE3D::GMessage.

Inherited by GAUGE3D::GKeyboardMessage, GAUGE3D::GMouseButtonMessage, GAUGE3D::GMouseMotionMessage, and GAUGE3D::GMouseWheelMessage.

List of all members.

Public Types

enum  tFlags { DIGITAL = 0, ANALOG = 1, ABSOLUTE = 0, RELATIVE = 2 }
 Indicates the type of input.


Public Methods

 GInputMessage (pGObject origin,GString name,float value,int flags)
 Create a GInputMessage with the given info. More...

virtual ~GInputMessage ()
bool IsAnalog ()
 Returns true if the input is analog, false if digital.

bool IsRelative ()
 Returns true if the input is relate, false if absolute.

int Type ()
 Returns the raw bitpattern type of the message. More...

float Value ()
 Returns the value of the input.

GString Name ()
 Returns an identifier for the input. More...


Detailed Description

Represents an input message.

Input messages can be analog or digital, and they can be relative or absolute. Here's what each combination means:


Constructor & Destructor Documentation

GAUGE3D::GInputMessage::GInputMessage ( pGObject origin,
GString name,
float value,
int flags ) [inline]
 

Create a GInputMessage with the given info.

Parameters:
origin   A pointer to the object which is the logical "originator" of the message. For example, most messages will originate from a GDisplay.
name   See Name(), below.
value   See Value(), below.
flags   A bitwise combination of the enum values of tFlags. The input must be either ANALOG or DIGITAL, and either ABSOLUTE or RELATIVE.


Member Function Documentation

int GAUGE3D::GInputMessage::Type ( ) [inline]
 

Returns the raw bitpattern type of the message.

Remarks:
This does not give you any more info than IsAnalog and IsRelative do.

GString GAUGE3D::GInputMessage::Name ( ) [inline]
 

Returns an identifier for the input.

The name of the input source is a human-readable unique identifier for the source of the input. In the case of a key on the keyboard, the name might be "a" or "left control". For a mouse button, it would be "mouse1" or "mouse3". For mouse movement, "mouse x" or "mouse y". Et cetera.


The documentation for this class was generated from the following file:
Generated at Tue Jan 30 17:07:34 2001 for gauge3d by doxygen1.2.4 written by Dimitri van Heesch, © 1997-2000