Rocket::Core::Event Class Reference
#include <Event.h>
Detailed Description
An event that propogates through the element hierarchy. Events follow the DOM3 event specification. See
http://www.w3.org/TR/DOM-Level-3-Events/events.html.
- Author:
- Lloyd Weehuizen
Constructor & Destructor Documentation
| Rocket::Core::Event::Event |
( |
Element * |
target, |
|
|
const String & |
type, |
|
|
const Dictionary & |
parameters, |
|
|
bool |
interruptible = false | |
|
) |
| | |
Constructor
- Parameters:
-
| [in] | target | The target element of this event |
| [in] | type | The event type |
| [in] | parameters | The event parameters |
| [in] | interruptible | Can this event have is propagation stopped? |
Member Function Documentation
| Event::EventPhase Rocket::Core::Event::GetPhase |
( |
|
) |
const |
Get the current propagation phase.
- Returns:
- Current phase the event is in.
| void Rocket::Core::Event::SetPhase |
( |
EventPhase |
phase |
) |
|
Set the current propagation phase
- Parameters:
-
| phase | Switch the phase the event is in |
| void Rocket::Core::Event::SetCurrentElement |
( |
Element * |
element |
) |
|
Set the current element in the propagation.
- Parameters:
-
| [in] | element | The current element. |
| Element * Rocket::Core::Event::GetCurrentElement |
( |
|
) |
const |
Get the current element in the propagation.
- Returns:
- The current element in propagation.
| Element * Rocket::Core::Event::GetTargetElement |
( |
|
) |
const |
Get the target element
- Returns:
- The target element of this event
| const String & Rocket::Core::Event::GetType |
( |
|
) |
const |
Get the event type.
- Returns:
- The event type.
| bool Rocket::Core::Event::operator== |
( |
const String & |
type |
) |
const |
Checks if the event is of a certain type.
- Parameters:
-
| type | The name of the type to check for. |
- Returns:
- True if the event is of the requested type, false otherwise.
| bool Rocket::Core::Event::IsPropagating |
( |
|
) |
const |
Has the event been stopped?
- Returns:
- True if the event is still propogating
template<typename T>
| T Rocket::Core::Event::GetParameter |
( |
const String & |
key, |
|
|
const T & |
default_value | |
|
) |
| | [inline] |
Returns the value of one of the event's parameters.
- Parameters:
-
| key[in] | The name of the desired parameter. |
- Returns:
- The value of the requested parameter.
| const Dictionary * Rocket::Core::Event::GetParameters |
( |
|
) |
const |
Access the dictionary of parameters
- Returns:
- The dictionary of parameters
The documentation for this class was generated from the following files:
- Include/Rocket/Core/Event.h
- Source/Core/Event.cpp