TRawEvent Class Reference

#include <e32event.h>

class TRawEvent
Public Attributes
TInt alpha
struct TRawEvent::@21::@24key
TInt modifiers
TInt phi
struct TRawEvent::@21::@22pos
struct TRawEvent::@21::@23pos3D
TInt repeats
TInt scanCode
TInt theta
TInt x
TInt y
TInt z
Protected Attributes
TUint8 iDeviceNumber
TUint8 iPointerNumber
TUint iTicks
TUint8 iTip
TUint8 iType
union TRawEvent::@21iU
Public Member Enumerations
enumTType { ENone, EPointerMove, EPointerSwitchOn, EKeyDown, ..., ERestartSystem }
Public Member Functions
TRawEvent()
TInt DeviceNumber()
TBool IsTip()
IMPORT_C TIntModifiers()
TUint8 PointerNumber()
IMPORT_C TPointPos()
IMPORT_C TPoint3DPos3D()
IMPORT_C TIntRepeats()
IMPORT_C TIntRotation()
IMPORT_C TIntScanCode()
IMPORT_C voidSet(TType, TInt)
IMPORT_C voidSet(TType, TInt, TInt)
IMPORT_C voidSet(TType)
IMPORT_C voidSet(TType, TInt, TInt, TInt)
IMPORT_C voidSet(TType, TInt, TInt, TInt, TInt, TInt, TInt)
IMPORT_C voidSet(TType, TInt, TInt, TInt, TUint8)
voidSetDeviceNumber(TInt)
voidSetPointerNumber(const TUint8)
IMPORT_C voidSetRepeat(TType, TInt, TInt)
IMPORT_C voidSetRotation(TType, TInt)
IMPORT_C voidSetTilt(TType, TInt, TInt)
voidSetTip(TBool)
TUint Ticks()
IMPORT_C TAngle3DTilt()
TType Type()

Detailed Description

Represents a raw hardware event as generated by hardware drivers of a pointer device, a keyboard etc.

Raw hardware events are added to the kernel's event queue.

Member Attribute Documentation

alpha

TInt alpha

iDeviceNumber

TUint8 iDeviceNumber[protected]

iPointerNumber

TUint8 iPointerNumber[protected]

iTicks

TUint iTicks[protected]

iTip

TUint8 iTip[protected]

Indicates whether the tip or head of pointing device is closer to screen.

iType

TUint8 iType[protected]

iU

union TRawEvent::@21iU[protected]

key

struct TRawEvent::@21::@24key

modifiers

TInt modifiers

phi

TInt phi

pos

struct TRawEvent::@21::@22pos

pos3D

struct TRawEvent::@21::@23pos3D

repeats

TInt repeats

scanCode

TInt scanCode

theta

TInt theta

x

TInt x

y

TInt y

z

TInt z

Member Enumeration Documentation

Enum TType

Defines the event type.

EnumeratorValueDescription
ENone

Represents an uninitialised event object.

EPointerMove

A pointer device (e.g. a pen) has moved. Only changes in Cartesian coordinates are tracked.

EPointerSwitchOn

A switch on event caused by a screen tap using a pointer device.

EKeyDown

Represents a keyboard key down event.

EKeyUp

Represents a keyboard key up event.

ERedraw

Represents a redraw event.

Typically generated in an emulator environment in response to a host OS redraw event.

ESwitchOn

Represents a device switch on event.

EActive
EInactive
EUpdateModifiers

Represents a modifier key being pressed.

EButton1Down

Represents a button down event.

This is typically used to represent a pointing device coming into contact with a touch sensitive screen.

EButton1Up

Represents a button up event.

This is typically used to represent a pointing device being lifted away from a touch sensitive screen.

EButton2Down

Represents a button down event.

This is typically used to represent a pointing device coming into contact with a touch sensitive screen.

EButton2Up

Represents a button up event.

This is typically used to represent a pointing device being lifted away from a touch sensitive screen.

EButton3Down

Represents a button down event.

This is typically used to represent a pointing device coming into contact with a touch sensitive screen.

EButton3Up

Represents a button up event.

This is typically used to represent a pointing device being lifted away from a touch sensitive screen.

ESwitchOff

Represents a device switch off event.

EKeyRepeat

Represents a key being continually pressed event.

ECaseOpen

Represents a case open event.

The meaning of a case is hardware specific.

ECaseClose

Represents a case close event.

The meaning of a case is hardware specific.

EPointer3DInRange

Represents a 3D pointer entering the detection volume event.

This is typically used to represent a pointing device coming into detection range of a sensitive screen.

EPointer3DOutOfRange

Represents a 3D pointer leaving the detection volume event.

This is typically used to represent a pointing device leaving the detection range of a sensitive screen.

EPointer3DTilt

Represents a 3D pointer tilt changes only event.

This is typically sent by a 3D pointer driver when it detects a change in the pointer's polar coordinates (Theta or Phi).

EPointer3DRotation

Represents a 3D pointer rotation only event.

This is typically sent by a 3D pointer driver when it detects a rotation of the pointing device (along ist main axis).

EPointer3DTiltAndMove

Represents a general 3D pointer changes event.

This is typically sent by a 3D pointer driver when it detects a change in the pointer's linear and/or polar coordinates and/or rotation.

EButton4Down

Reserved for a 3D pointing device button down event.

EButton4Up

Reserved for a 3D pointing device button up event.

EButton5Down

Reserved for a 3D pointing device button down event.

EButton5Up

Reserved for a 3D pointing device button up event.

EButton6Down

Reserved for a 3D pointing device button down event.

EButton6Up

Reserved for a 3D pointing device button up event.

ERestartSystem

Represents a device restart event.

Constructor & Destructor Documentation

TRawEvent ( )

TRawEvent()[inline]

Default constructor

Member Function Documentation

DeviceNumber ( )

TInt DeviceNumber()const [inline]

Gets the device number (eg. screen number)

Return Value
The device number.

IsTip ( )

TBool IsTip()const [inline]

Gets the information on which end of the pointing device is closer to the screen

Return Value
A Boolean indicating which end of the pointing device is closer to the screen.

Modifiers ( )

IMPORT_C TIntModifiers()const

Gets the modifiers.

See also: TRawEvent::EUpdateModifiers

Return Value
The modifiers.
Panic Codes
EUSER34 If the event does not represent a modifier key being pressed, i.e. if the event type is not

PointerNumber ( )

TUint8 PointerNumber()const [inline]

Return Value
the pointer number of the the event

Pos ( )

IMPORT_C TPointPos()const

Gets the mouse or digitiser X-Y position.

Return Value
The position.

Pos3D ( )

IMPORT_C TPoint3DPos3D()const

Gets the Cartesian coordinates of the 3D pointer end that is closer to the screen.

Gets the 3D pointing device Cartesian coordinates.

Return Value
The Cartesian coordinates of the point defined by the end of the 3D pointing device that is closer to the screen.The position.

Repeats ( )

IMPORT_C TIntRepeats()const

Gets the repeat count.

Return Value
The repeat count.

Rotation ( )

IMPORT_C TIntRotation()const

Gets the rotation angle of 3D pointing device.

Some 3D pointing devices support information regarding the angle formed between the physical and magnetical poles, as obtaining when rotating the pen along its main axis.

Gets the rotation angle of 3D pointing device.

Return Value
The rotation angle of the 3D pointing device.The rotation angle of the 3D pointing device.

ScanCode ( )

IMPORT_C TIntScanCode()const

Gets the scancode.

Return Value
The scancode.

Set ( TType, TInt )

IMPORT_C voidSet(TTypeaType,
TIntaScanCode
)

Sets the event up as a scancode event.

Parameters
aTypeThe event type.
aScanCodeThe scancode.

Set ( TType, TInt, TInt )

IMPORT_C voidSet(TTypeaType,
TIntaX,
TIntaY
)

Sets the event up as a mouse/pen event.

Parameters
aTypeThe event type.
aXThe X position.
aYThe Y position.

Set ( TType )

IMPORT_C voidSet(TTypeaType)

Sets up an event without specific parameters.

Parameters
aTypeThe event type.

Set ( TType, TInt, TInt, TInt )

IMPORT_C voidSet(TTypeaType,
TIntaX,
TIntaY,
TIntaZ
)

Sets the event up as a 3D pointer linear move event.

Parameters
aTypeThe event type.
aXThe X position.
aYThe Y position.
aZThe Z position (defaults to 0 on 2D detection devices) .

Set ( TType, TInt, TInt, TInt, TInt, TInt, TInt )

IMPORT_C voidSet(TTypeaType,
TIntaX,
TIntaY,
TIntaZ,
TIntaPhi,
TIntaTheta,
TIntaAlpha
)

Sets the event up as a 3D pointer linear move and tilt and rotation change event.

Parameters
aTypeThe event type.
aXThe X position (or TPhi polar coordinate).
aYThe Y position (or Theta polar coordinate).
aZThe Z position (or rotation).
aPhiThe Phi polar coordinate.
aThetaThe Theta polar coordinate.
aAlphaThe rotation angle.

Set ( TType, TInt, TInt, TInt, TUint8 )

IMPORT_C voidSet(TTypeaType,
TIntaX,
TIntaY,
TIntaZ,
TUint8aPointerNumber
)

Initialises the event with the supplied information Sets the event up as a 3D pointer linear move event with pointer number

Parameters
aTypeThe event type.
aXThe X position.
aYThe Y position.
aZThe Z position .
aPointerNumberThe pointer number for the event

SetDeviceNumber ( TInt )

voidSetDeviceNumber(TIntaDeviceNumber)[inline]

Sets the device number (eg. screen number)

Parameters
aDeviceNumberThe device number

SetPointerNumber ( const TUint8 )

voidSetPointerNumber(const TUint8aPointerNumber)[inline]

The pointer number for the event is set The pointer number should be more or equal 0 and should be less than HALData::EPointerMaxPointers, otherwise WSERV would ignore the event,ie 0 <= aPointerNumber < HALData::EPointerMaxPointers

Parameters
aPointerNumberError conditions: None.

SetRepeat ( TType, TInt, TInt )

IMPORT_C voidSetRepeat(TTypeaType,
TIntaScanCode,
TIntaRepeats
)

Sets the event up as a repeating scancode event.

Parameters
aTypeThe event type.
aScanCodeThe scancode.
aRepeatsThe repeat count.

SetRotation ( TType, TInt )

IMPORT_C voidSetRotation(TTypeaType,
TIntaAlpha
)

Sets the event up as 3D pointer rotation event.

Parameters
aTypeThe event type.
aAlphaThe rotation angle.

SetTilt ( TType, TInt, TInt )

IMPORT_C voidSetTilt(TTypeaType,
TIntaPhi,
TIntaTheta
)

Sets the event up as 3D pointer tilt change event.

Parameters
aTypeThe event type.
aPhiThe Phi coordinate.
aThetaThe Theta coordinate.

SetTip ( TBool )

voidSetTip(TBoolaTip)[inline]

Sets the information on which end of the pointing device is closer to the screen

Parameters
aTipA Boolean indicating which end of the pointing device is closer to the screen.

Ticks ( )

TUint Ticks()const [inline]

Gets the tick count value associated with the event.

Note that the interval between tick counts is hardware dependent.

Return Value
The tick count value

Tilt ( )

IMPORT_C TAngle3DTilt()const

Gets the angular spherical polar coordinates of the 3D pointer end that is closer to the screen.

See also: TAngle3D

Gets the 3D pointing device polar coordinates and rotation.

Return Value
The angular spherical polar coordinates of the point defined by the end of the 3D pointing device that is closer to the screen. The polar coordinates and rotation.

Type ( )

TType Type()const [inline]

Gets the event type

Return Value
The event type.