omgui::EventManager Class Reference

#include <omgui/event.h>

List of all members.


Detailed Description

The Manager drives the event system. It stores and invokes all slots.

Static Public Member Functions

static Connection connect (object_id object, event_id event, SlotBase *slot, int priority=SIGNAL_PRIORITY_NORMAL)
static void disconnect_all ()
static void disconnect_all (object_id object)
static bool send_event (const Event &event)

Private Types

typedef std::map< event_id,
Signal
EventSignals
typedef std::map< object_id,
EventSignals
ObjectEventSignals
typedef std::map< int,
SignalsGroup
Signals

Static Private Member Functions

static bool send_event (SignalsGroup &group, const Event &event, bool &processed)

Static Private Attributes

static std::deque
< ObjectEventEraseBufferData
object_event_erase_buffer
static int sending_event = 0
static Signals signals

Classes

struct  ObjectEventEraseBufferData
struct  SignalsGroup

Member Typedef Documentation

typedef std::map<event_id, Signal> omgui::EventManager::EventSignals [private]

typedef std::map<int, SignalsGroup> omgui::EventManager::Signals [private]


Member Function Documentation

Connection omgui::EventManager::connect ( object_id  object,
event_id  event,
SlotBase slot,
int  priority = SIGNAL_PRIORITY_NORMAL 
) [static]

Connects a slot to recieve an event with the specified event_id that is associated with the specified object_id. You can connect a slot that recieves any event by using EVENT_ID_ANY. You can also recieve events associated with any object by using OBJECT_ID_ANY.

Parameters:
object The object_d associated with the event you want to reciever
event The event_id of the event you want to recieve
slot The slot function to be invoked to recieve the event
priority Indicates the priority of the slot. Slots with higher priority are signaled before slots with lower priority.
See also:
omgui::make_slot

void omgui::EventManager::disconnect_all (  )  [static]

Disconnects all currently connected slots

void omgui::EventManager::disconnect_all ( object_id  object  )  [static]

Disconnects all connected slots for the specified object_id. Called automatically when a Widget is destroyed.

bool omgui::EventManager::send_event ( SignalsGroup group,
const Event event,
bool &  processed 
) [static, private]

Sends the given event to the slots in the given SignalsGroup.

Returns:
Returns true if event processing should continue to the next slot group.

bool omgui::EventManager::send_event ( const Event event  )  [static]

Sends an event


Member Data Documentation

int omgui::EventManager::sending_event = 0 [static, private]


doxygen SourceForge.net Logo