mirror of
https://github.com/AntonioND/tobkit.git
synced 2025-06-21 18:15:35 -04:00
84 lines
7.3 KiB
HTML
84 lines
7.3 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
|
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
|
|
<title>libsigc++ 2.0: Slots</title>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css">
|
|
</head>
|
|
<body bgcolor="#ffffff">
|
|
<table border="0" width="100%">
|
|
<tr>
|
|
<td width="10%" height="40"><img src="../../images/libsigc_logo.gif" alt="logo" border="0" width="100%" height="100%"/></td>
|
|
<td width="90%" height="40"><img src="../../images/top.gif" alt="top" width="100%" height="40"/></td>
|
|
</tr>
|
|
</table>
|
|
<center>
|
|
<a class="qindex" href="../../index.html">Main Page</a>
|
|
<a class="qindex" href="modules.html">Groups</a>
|
|
<a class="qindex" href="namespaces.html"> Namespaces</a>
|
|
</center>
|
|
<hr width="100%"/>
|
|
|
|
<!-- Generated by Doxygen 1.5.1 -->
|
|
<h1>Slots<br>
|
|
<small>
|
|
[<a class="el" href="group__functors.html">Functors</a>]</small>
|
|
</h1>
|
|
<p>
|
|
Collaboration diagram for Slots:<center><table><tr><td><img src="group__slot.png" border="0" alt="" usemap="#group____slot_map">
|
|
<map name="group____slot_map">
|
|
<area href="group__functors.html" shape="rect" coords="7,5,81,32" alt="">
|
|
</map></td></tr></table></center>
|
|
Slots are type-safe representations of callback methods and functions.
|
|
<a href="#_details">More...</a><table border="0" cellpadding="0" cellspacing="0">
|
|
<tr><td></td></tr>
|
|
<tr><td colspan="2"><br><h2>Classes</h2></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><a class="el" href="classsigc_1_1slot0.html">sigc::slot0<T_return></a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Converts an arbitrary functor to a unified type which is opaque. <a href="classsigc_1_1slot0.html#_details">More...</a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><a class="el" href="classsigc_1_1slot1.html">sigc::slot1<T_return, T_arg1></a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Converts an arbitrary functor to a unified type which is opaque. <a href="classsigc_1_1slot1.html#_details">More...</a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><a class="el" href="classsigc_1_1slot2.html">sigc::slot2<T_return, T_arg1, T_arg2></a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Converts an arbitrary functor to a unified type which is opaque. <a href="classsigc_1_1slot2.html#_details">More...</a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><a class="el" href="classsigc_1_1slot3.html">sigc::slot3<T_return, T_arg1, T_arg2, T_arg3></a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Converts an arbitrary functor to a unified type which is opaque. <a href="classsigc_1_1slot3.html#_details">More...</a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><a class="el" href="classsigc_1_1slot4.html">sigc::slot4<T_return, T_arg1, T_arg2, T_arg3, T_arg4></a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Converts an arbitrary functor to a unified type which is opaque. <a href="classsigc_1_1slot4.html#_details">More...</a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><a class="el" href="classsigc_1_1slot5.html">sigc::slot5<T_return, T_arg1, T_arg2, T_arg3, T_arg4, T_arg5></a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Converts an arbitrary functor to a unified type which is opaque. <a href="classsigc_1_1slot5.html#_details">More...</a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><a class="el" href="classsigc_1_1slot6.html">sigc::slot6<T_return, T_arg1, T_arg2, T_arg3, T_arg4, T_arg5, T_arg6></a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Converts an arbitrary functor to a unified type which is opaque. <a href="classsigc_1_1slot6.html#_details">More...</a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><a class="el" href="classsigc_1_1slot7.html">sigc::slot7<T_return, T_arg1, T_arg2, T_arg3, T_arg4, T_arg5, T_arg6, T_arg7></a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Converts an arbitrary functor to a unified type which is opaque. <a href="classsigc_1_1slot7.html#_details">More...</a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><a class="el" href="classsigc_1_1slot.html">sigc::slot<T_return, T_arg1, T_arg2, T_arg3, T_arg4, T_arg5, T_arg6, T_arg7></a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Convenience wrapper for the numbered <a class="el" href="classsigc_1_1slot.html">sigc::slot</a># templates. <a href="classsigc_1_1slot.html#_details">More...</a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><a class="el" href="classsigc_1_1slot__base.html">sigc::slot_base</a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Base type for slots. <a href="classsigc_1_1slot__base.html#_details">More...</a><br></td></tr>
|
|
</table>
|
|
<hr><a name="_details"></a><h2>Detailed Description</h2>
|
|
Slots are type-safe representations of callback methods and functions.
|
|
<p>
|
|
A Slot can be constructed from any function, regardless of whether it is a global function, a member method, static, or virtual.<p>
|
|
Use the <a class="el" href="group__mem__fun.html#g7d9ea809173f48bf5c76cf1989591602">sigc::mem_fun()</a> and <a class="el" href="group__ptr__fun.html#gda8b678665c14dc85eb32d25b7299465">sigc::ptr_fun()</a> template functions to get a <a class="el" href="classsigc_1_1slot.html">sigc::slot</a>, like so:<p>
|
|
<div class="fragment"><pre class="fragment"> <a class="code" href="classsigc_1_1slot.html">sigc::slot<void, int></a> sl = <a class="code" href="group__mem__fun.html#g7d9ea809173f48bf5c76cf1989591602">sigc::mem_fun</a>(someobj,& SomeClass::somemethod);
|
|
</pre></div><p>
|
|
or<p>
|
|
<div class="fragment"><pre class="fragment"> <a class="code" href="classsigc_1_1slot.html">sigc::slot<void, int></a> sl = <a class="code" href="group__ptr__fun.html#gda8b678665c14dc85eb32d25b7299465">sigc::ptr_fun</a>(&somefunction);
|
|
</pre></div><p>
|
|
or<p>
|
|
<div class="fragment"><pre class="fragment"> m_Button.signal_clicked().connect( <a class="code" href="group__mem__fun.html#g7d9ea809173f48bf5c76cf1989591602">sigc::mem_fun</a>(*<span class="keyword">this</span>, &MyWindow::on_button_clicked) );
|
|
</pre></div><p>
|
|
The compiler will complain if SomeClass::somemethod, etc. have the wrong signature.<p>
|
|
You can also pass slots as method parameters where you might normally pass a function pointer. <hr><address><small>
|
|
Generated for libsigc++ 2.0 by <a href="http://www.doxygen.org/index.html">
|
|
Doxygen</a> 1.5.1 © 1997-2001</small></address>
|
|
</body>
|
|
</html>
|