Crazy Eddie's GUI System  0.8.7
CEGUI::Event::ScopedConnection Class Reference

Event::Connection wrapper that automatically disconnects the connection when the object is deleted (or goes out of scope). More...

+ Inheritance diagram for CEGUI::Event::ScopedConnection:
+ Collaboration diagram for CEGUI::Event::ScopedConnection:

Public Member Functions

 ScopedConnection (const Event::Connection &connection)
 
ScopedConnectionoperator= (const Event::Connection &connection)
 
bool connected () const
 
void disconnect ()
 
- Public Member Functions inherited from CEGUI::RefCounted< T >
 RefCounted ()
 Default constructor.
 
 RefCounted (T *ob)
 Contruct a RefCounted object that wraps the pointer ob.
 
 RefCounted (const RefCounted< T > &other)
 Copy constructor.
 
 ~RefCounted ()
 Destructor. Only deletes the associated object if no further references exist.
 
RefCounted< T > & operator= (const RefCounted< T > &other)
 Assignment operator. Previously held object gets its reference count reduced, and is deleted if no further references exist. The newly assigned object, taken from other, gets its count increased.
 
bool operator== (const RefCounted< T > &other) const
 Return whether the two RefCounted ptrs are equal (point to the same object)
 
bool operator!= (const RefCounted< T > &other) const
 Return whether the two RefCounted ptrs are not equal (point to different objects)
 
const T & operator* () const
 Return the object referred to by the wrapped pointer. (beware of null pointers when using this!)
 
T & operator* ()
 
const T * operator-> () const
 Return the wrapped pointer.
 
T * operator-> ()
 
bool isValid () const
 Return whether the wrapped pointer is valid. i.e. that it is not null.
 

Detailed Description

Event::Connection wrapper that automatically disconnects the connection when the object is deleted (or goes out of scope).