#include <omgui/event.h>
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 |
typedef std::map<event_id, Signal> omgui::EventManager::EventSignals [private] |
typedef std::map<object_id, EventSignals> omgui::EventManager::ObjectEventSignals [private] |
typedef std::map<int, SignalsGroup> omgui::EventManager::Signals [private] |
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.
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. |
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.
bool omgui::EventManager::send_event | ( | const Event & | event | ) | [static] |
Sends an event
std::deque< EventManager::ObjectEventEraseBufferData > omgui::EventManager::object_event_erase_buffer [static, private] |
int omgui::EventManager::sending_event = 0 [static, private] |
EventManager::Signals omgui::EventManager::signals [static, private] |