#include <omgui/event.h>
Public Types | |
typedef Pointer< SlotBase > | slot_type |
Public Member Functions | |
Connection | connect (const slot_type &slot) |
void | disconnect_all () |
bool | operator() (const Event &) |
Signal () | |
~Signal () | |
Private Types | |
typedef std::queue < Slots::iterator > | DisconnectedSlots |
typedef std::list< Pointer < ConnectionImpl > > | Slots |
Private Member Functions | |
void | disconnect (const Slots::iterator &it) |
Private Attributes | |
DisconnectedSlots | disconnected_slots |
int | signaling_ |
Slots | slots |
Friends | |
class | ConnectionImpl |
typedef std::queue<Slots::iterator> omgui::Signal::DisconnectedSlots [private] |
typedef Pointer<SlotBase> omgui::Signal::slot_type |
typedef std::list< Pointer<ConnectionImpl> > omgui::Signal::Slots [private] |
omgui::Signal::Signal | ( | ) |
omgui::Signal::~Signal | ( | ) |
Disconnects all slots connected to the signal
Connection omgui::Signal::connect | ( | const slot_type & | slot | ) |
Connects a slot to this signal. A Connection object is returned to manage the connection. It can be used to disconnect the slot.
void omgui::Signal::disconnect | ( | const Slots::iterator & | it | ) | [private] |
Used by ConnectionImpl to disconnect slots safely. If this signal is currently signaling its slots, the slot will be queued for removal but will not be signaled
void omgui::Signal::disconnect_all | ( | ) |
Disconnects all slots connected to this signal
bool omgui::Signal::operator() | ( | const Event & | event | ) |
Signals all of the connected slots.
friend class ConnectionImpl [friend] |
int omgui::Signal::signaling_ [private] |
Slots omgui::Signal::slots [private] |