GL Studio C++ Runtime API
ObjectEvent Class Reference

#include <events.h>

Inheritance diagram for ObjectEvent:
DisplayEvent

Public Member Functions

 ObjectEvent (DisplayObject *initiator, const char *eventName, const char *eventData=NULL)
 
 ObjectEvent (DisplayObject *initiator, unsigned short eventSubtypeArg)
 
DisplayObjectInitiator () const
 
void Initiator (DisplayObject *initiator)
 
const char * EventName () const
 
void EventName (const char *newName)
 
const char * EventData () const
 
void EventData (const char *newData)
 
bool EventNameIs (const char *eventName) const
 
bool EventDataIs (const char *eventData) const
 
- Public Member Functions inherited from DisplayEvent
 DisplayEvent ()
 
 DisplayEvent (const DisplayEvent &source)
 
virtual ~DisplayEvent ()
 

Additional Inherited Members

- Public Attributes inherited from DisplayEvent
unsigned short eventType
 
unsigned short eventSubtype
 

Detailed Description

The ObjectEvent class This event is intended to be emitted by objects, rather than by a mouse or keyboard.

Constructor & Destructor Documentation

◆ ObjectEvent() [1/2]

ObjectEvent ( DisplayObject initiator,
const char *  eventName,
const char *  eventData = NULL 
)
inline

Create an ObjectEvent, setting the initator and event name

Parameters
initiatorPointer to the object that initated the event
eventNameName of the event
eventDataData of the event

◆ ObjectEvent() [2/2]

ObjectEvent ( DisplayObject initiator,
unsigned short  eventSubtypeArg 
)
inline

Create an ObjectEvent, setting the initator and event subtype

Parameters
initiatorPointer to the object that initated the event
eventSubtypeArgThe arbitrary event subtype

Member Function Documentation

◆ EventData() [1/2]

const char * EventData ( ) const
inline
Returns
The data of the event, NULL terminated

◆ EventData() [2/2]

void EventData ( const char *  newData)
inline

Set the data of the event, NULL terminated. For CRT safety, this should only be called by the constructing code

Parameters
newDataThe name to set

◆ EventDataIs()

bool EventDataIs ( const char *  eventData) const
inline
Parameters
eventDataThe name to compare.
Returns
True if the name of this event matches the given name.

◆ EventName() [1/2]

const char * EventName ( ) const
inline
Returns
The name of the event

◆ EventName() [2/2]

void EventName ( const char *  newName)
inline

Set the name of the event For CRT safety, this should only be called by the constructing code

Parameters
newNameThe name to set

◆ EventNameIs()

bool EventNameIs ( const char *  eventName) const
inline
Parameters
eventNameThe name to compare.
Returns
True if the name of this event matches the given name.

◆ Initiator() [1/2]

DisplayObject * Initiator ( ) const
inline
Returns
Pointer to the object that initiated the event (may be NULL)

◆ Initiator() [2/2]

void Initiator ( DisplayObject initiator)
inline

Set which object initiated the event

Parameters
initiatorPointer to the object that initiated the event

The documentation for this class was generated from the following file: