rwlogo
Rogue Wave Views 5.6

Rogue Wave Views
Prototypes Package API Reference Guide

Product Documentation:

Rogue Wave Views
Documentation Home

IlvEventAccessor Class Reference

Handling events behavior (usually mouse or keyboard events). More...

#include <ilviews/protos/eventacc.h>

Inheritance diagram for IlvEventAccessor:
IlvAbstractEventAccessor IlvUserAccessor IlvAccessor

List of all members.

Public Member Functions

 IlvEventAccessor (const char *name, const IlvValueTypeClass *type, const char *nodeName, IlvEventType eventType, IlUShort detail, IlUShort modifiers, IlvEventAccessorData whichData)
 Creates an event accessor.
virtual IlBoolean handleEvent (IlvAccessorHolder *object, IlvGraphic *g, IlvEvent &, IlvView *, IlvTransformer *t)
 Filters the events and performs the value change of the attribute (if appropriate).

Detailed Description

Handling events behavior (usually mouse or keyboard events).

Library: ilvproto

IlvEventAccessor is a subtype of the IlvAbstractEventAccessor class that handles events of a specified type. When an event is received, the attribute value is set to one of the data members of the event.

See also:
IlvEventAccessorData, IlvEvent, IlvEventType.

Constructor & Destructor Documentation

IlvEventAccessor::IlvEventAccessor ( const char *  name,
const IlvValueTypeClass type,
const char *  nodeName,
IlvEventType  eventType,
IlUShort  detail,
IlUShort  modifiers,
IlvEventAccessorData  whichData 
)

Creates an event accessor.

Parameters:
name Name of the attribute that handles events.
type Type of the attribute that handles events.
nodeName Name of the node for which events are handled. If nodeName is "[All_nodes]", the accessor handles user events received by any node of the group to which it is attached. If nodeName is the name of a subgroup, the accessor handles events received by any node of the subgroup.
eventType Type of the events that must be handled (for example, IlvButtonDown).
detail Code of the events. For example IlvLeftButton, the ASCII code of the character `a', or the key code IlvReturn.
modifiers A mask specifying a combination of modifier keys that must be pressed, for example IlvCtrlModifier|IlvShiftModifier. Only the events with the specified modifiers will be handled. Use IlvAnyModifier to ignore the modifiers of the event.
whichData Specifies which data member of the event the accessor value will be set to.
See also:
IlvEventAccessorData, IlvEventType.

Member Function Documentation

virtual IlBoolean IlvEventAccessor::handleEvent ( IlvAccessorHolder object,
IlvGraphic g,
IlvEvent ,
IlvView ,
IlvTransformer t 
) [virtual]

Filters the events and performs the value change of the attribute (if appropriate).

Filters the events according to the eventType, detail, and modifiers parameters of the constructor. Then, it calls IlvAccessible::changeValue to set the accessor value to the event data member specified by the whichData parameter.

See also:
IlvAbstractEventAccessor::handleEvent.

Reimplemented from IlvAbstractEventAccessor.

 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

© Copyright 2012, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.