![]() |
![]() |
Inheritance diagram for sigc::signal< T_return, T_arg1, T_arg2, T_arg3, T_arg4, T_arg5, T_arg6, T_arg7 >:
Public Member Functions | |
signal () | |
signal (const signal& src) | |
Classes | |
class | accumulated |
Convenience wrapper for the numbered sigc::signal# templates. More... |
signal can be used to connect() slots that are invoked during subsequent calls to emit(). Any functor or slot can be passed into connect(). It is converted into a slot implicitly.
If you want to connect one signal to another, use make_slot() to retrieve a functor that emits the signal when invoked.
Be careful if you directly pass one signal into the connect() method of another: a shallow copy of the signal is made and the signal's slots are not disconnected until both the signal and its clone are destroyed which is probably not what you want!
An STL-style list interface for the signal's list of slots can be retrieved with slots(). This interface supports iteration, insertion and removal of slots.
The template arguments determine the function signature of the emit() function:
nil
means no argument.nil
means no argument.nil
means no argument.nil
means no argument.nil
means no argument.nil
means no argument.nil
means no argument.To specify an accumulator type the nested class signal::accumulated can be used.
void foo(int) {} sigc::signal<void, long> sig; sig.connect(sigc::ptr_fun(&foo)); sig.emit(19);
sigc::signal<T_return, T_arg1, T_arg2, T_arg3, T_arg4, T_arg5, T_arg6, T_arg7>::signal | ( | ) | [inline] |
sigc::signal<T_return, T_arg1, T_arg2, T_arg3, T_arg4, T_arg5, T_arg6, T_arg7>::signal | ( | const signal<T_return, T_arg1, T_arg2, T_arg3, T_arg4, T_arg5, T_arg6, T_arg7>& | src | ) | [inline] |