File: classWt_1_1WSubMenuItem.html

package info (click to toggle)
witty 3.2.1-2%2Bdeb7u1
  • links: PTS
  • area: main
  • in suites: wheezy
  • size: 70,436 kB
  • sloc: cpp: 117,095; ansic: 77,999; xml: 7,564; sh: 1,037; perl: 208; makefile: 144; java: 86; sql: 14
file content (373 lines) | stat: -rw-r--r-- 26,352 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>Wt: Wt::WSubMenuItem Class Reference</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />

<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>

</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">Wt
   &#160;<span id="projectnumber">3.2.1</span>
   </div>
   
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.7.5.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="namespaceWt.html">Wt</a>      </li>
      <li class="navelem"><a class="el" href="classWt_1_1WSubMenuItem.html">WSubMenuItem</a>      </li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pro-methods">Protected Member Functions</a>  </div>
  <div class="headertitle">
<div class="title">Wt::WSubMenuItem Class Reference</div>  </div>
</div>
<div class="contents">
<!-- doxytag: class="Wt::WSubMenuItem" --><!-- doxytag: inherits="Wt::WMenuItem" -->
<p>A menu item that contains a nested sub menu.  
 <a href="classWt_1_1WSubMenuItem.html#details">More...</a></p>
<div class="dynheader">
Inheritance diagram for Wt::WSubMenuItem:</div>
<div class="dyncontent">
<div class="center"><img src="classWt_1_1WSubMenuItem__inherit__graph.png" border="0" usemap="#Wt_1_1WSubMenuItem_inherit__map" alt="Inheritance graph"/></div>
<map name="Wt_1_1WSubMenuItem_inherit__map" id="Wt_1_1WSubMenuItem_inherit__map">
<area shape="rect" href="classWt_1_1WMenuItem.html" title="A single item in a menu." alt="" coords="17,80,132,107"/><area shape="rect" href="classWt_1_1WObject.html" title="A base class for objects that participate in the signal/slot system." alt="" coords="27,5,123,32"/></map>
<center><span class="legend">[<a href="graph_legend.html">legend</a>]</span></center></div>

<p><a href="classWt_1_1WSubMenuItem-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WSubMenuItem.html#a0c56dcd20f9d6afaaf289d2270e3b296">WSubMenuItem</a> (const <a class="el" href="classWt_1_1WString.html">WString</a> &amp;text, <a class="el" href="classWt_1_1WWidget.html">WWidget</a> *contents, <a class="el" href="classWt_1_1WMenuItem.html#a5e276ed0505694a7b89a1dd0c62aa55a">LoadPolicy</a> policy=LazyLoading)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates a new item.  <a href="#a0c56dcd20f9d6afaaf289d2270e3b296"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WSubMenuItem.html#a33eccd31a4aa8436cf66effa2cecf94b">setSubMenu</a> (<a class="el" href="classWt_1_1WMenu.html">WMenu</a> *subMenu)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets a sub menu.  <a href="#a33eccd31a4aa8436cf66effa2cecf94b"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classWt_1_1WMenu.html">WMenu</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WSubMenuItem.html#aa30469d72bfdec0c85181f012e269e9f">subMenu</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the sub menu.  <a href="#aa30469d72bfdec0c85181f012e269e9f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual std::string&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WSubMenuItem.html#af774d49f24f2ee362cc28eb688cb9eef">pathComponent</a> () const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the path component for this item.  <a href="#af774d49f24f2ee362cc28eb688cb9eef"></a><br/></td></tr>
<tr><td colspan="2"><h2><a name="pro-methods"></a>
Protected Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classWt_1_1WWidget.html">WWidget</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WSubMenuItem.html#a3883ce17fd7d04553510700189fbc7af">createItemWidget</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates the widget that represents the item.  <a href="#a3883ce17fd7d04553510700189fbc7af"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WSubMenuItem.html#a44820d1555db0e1f6593dd80d1c0b34e">updateItemWidget</a> (<a class="el" href="classWt_1_1WWidget.html">WWidget</a> *itemWidget)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Updates the widget that represents the item.  <a href="#a44820d1555db0e1f6593dd80d1c0b34e"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WSubMenuItem.html#ad3096bef2abbc291cb2560cd16d92458">renderSelected</a> (bool selected)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Renders the item as selected or unselected.  <a href="#ad3096bef2abbc291cb2560cd16d92458"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classWt_1_1SignalBase.html">SignalBase</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WSubMenuItem.html#a38d7a0fa3581f34aa72c9fd4d1a6eaeb">activateSignal</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the signal used to activate the item.  <a href="#a38d7a0fa3581f34aa72c9fd4d1a6eaeb"></a><br/></td></tr>
</table>
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>A menu item that contains a nested sub menu. </p>
<p>This class specializes menu item to have an optional sub menu.</p>
<p>When the item is shown and hidden when the item is selected respectively deselected.</p>
<p>Usage example: </p>
<div class="fragment"><pre class="fragment"> <span class="comment">// create the stack where the contents will be located</span>
 <a class="code" href="classWt_1_1WStackedWidget.html" title="A container widget that stacks its widgets on top of each other.">Wt::WStackedWidget</a> *contents = <span class="keyword">new</span> <a class="code" href="classWt_1_1WStackedWidget.html" title="A container widget that stacks its widgets on top of each other.">Wt::WStackedWidget</a>();

 <span class="comment">// create a top-level menu</span>
 <a class="code" href="classWt_1_1WMenu.html" title="A widget that shows a menu of options.">Wt::WMenu</a> *menu = <span class="keyword">new</span> <a class="code" href="classWt_1_1WMenu.html" title="A widget that shows a menu of options.">Wt::WMenu</a>(contents, <a class="code" href="namespaceWt.html#a2a8d45559e16a0185bf61bfad0a67912af916b7ec24727db2d972f0770170c7f5" title="Vertical.">Wt::Vertical</a>);

 <span class="comment">// add two plain items</span>
 menu-&gt;<a class="code" href="classWt_1_1WMenu.html#ad7840197cc0caf0430792b9f4a0df60d" title="Adds an item.">addItem</a>(<span class="stringliteral">&quot;Introduction&quot;</span>, <span class="keyword">new</span> <a class="code" href="classWt_1_1WText.html" title="A widget that renders (XHTML) text.">Wt::WText</a>(tr(<span class="stringliteral">&quot;intro&quot;</span>));
 menu-&gt;<a class="code" href="classWt_1_1WMenu.html#ad7840197cc0caf0430792b9f4a0df60d" title="Adds an item.">addItem</a>(<span class="stringliteral">&quot;Download&quot;</span>, <span class="keyword">new</span> <a class="code" href="classWt_1_1WText.html" title="A widget that renders (XHTML) text.">Wt::WText</a>(<span class="stringliteral">&quot;Not yet available&quot;</span>));

 <span class="comment">// add an item with a sub menu</span>
 <a class="code" href="classWt_1_1WSubMenuItem.html" title="A menu item that contains a nested sub menu.">Wt::WSubMenuItem</a> *examples = <span class="keyword">new</span> <a class="code" href="classWt_1_1WSubMenuItem.html#a0c56dcd20f9d6afaaf289d2270e3b296" title="Creates a new item.">Wt::WSubMenuItem</a>(<span class="stringliteral">&quot;Examples&quot;</span>, <span class="keyword">new</span> <a class="code" href="classWt_1_1WText.html" title="A widget that renders (XHTML) text.">Wt::WText</a>(tr(<span class="stringliteral">&quot;examples&quot;</span>)));
 <a class="code" href="classWt_1_1WMenu.html" title="A widget that shows a menu of options.">Wt::WMenu</a> *examplesMenu = <span class="keyword">new</span> <a class="code" href="classWt_1_1WMenu.html" title="A widget that shows a menu of options.">Wt::WMenu</a>(contents, <a class="code" href="namespaceWt.html#a2a8d45559e16a0185bf61bfad0a67912af916b7ec24727db2d972f0770170c7f5" title="Vertical.">Wt::Vertical</a>);
 examplesMenu-&gt;<a class="code" href="classWt_1_1WMenu.html#ad7840197cc0caf0430792b9f4a0df60d" title="Adds an item.">addItem</a>(<span class="stringliteral">&quot;Hello world&quot;</span>, <span class="keyword">new</span> <a class="code" href="classWt_1_1WText.html" title="A widget that renders (XHTML) text.">Wt::WText</a>(tr(<span class="stringliteral">&quot;example.hello-world&quot;</span>)));
 examplesMenu-&gt;<a class="code" href="classWt_1_1WMenu.html#ad7840197cc0caf0430792b9f4a0df60d" title="Adds an item.">addItem</a>(<span class="stringliteral">&quot;Shopping cart&quot;</span>, <span class="keyword">new</span> <a class="code" href="classWt_1_1WText.html" title="A widget that renders (XHTML) text.">Wt::WText</a>(tr(<span class="stringliteral">&quot;example.shopping&quot;</span>)));
 examples-&gt;<a class="code" href="classWt_1_1WSubMenuItem.html#a33eccd31a4aa8436cf66effa2cecf94b" title="Sets a sub menu.">setSubMenu</a>(examplesMenu);
 menu-&gt;<a class="code" href="classWt_1_1WMenu.html#ad7840197cc0caf0430792b9f4a0df60d" title="Adds an item.">addItem</a>(examples);

 addWidget(menu);
 addWidget(contents);
</pre></div><dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WMenuItem.html" title="A single item in a menu.">WMenuItem</a>, <a class="el" href="classWt_1_1WMenu.html" title="A widget that shows a menu of options.">WMenu</a> </dd></dl>
</div><hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a0c56dcd20f9d6afaaf289d2270e3b296"></a><!-- doxytag: member="Wt::WSubMenuItem::WSubMenuItem" ref="a0c56dcd20f9d6afaaf289d2270e3b296" args="(const WString &amp;text, WWidget *contents, LoadPolicy policy=LazyLoading)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">Wt::WSubMenuItem::WSubMenuItem </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classWt_1_1WString.html">WString</a> &amp;&#160;</td>
          <td class="paramname"><em>text</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classWt_1_1WWidget.html">WWidget</a> *&#160;</td>
          <td class="paramname"><em>contents</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classWt_1_1WMenuItem.html#a5e276ed0505694a7b89a1dd0c62aa55a">LoadPolicy</a>&#160;</td>
          <td class="paramname"><em>policy</em> = <code>LazyLoading</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Creates a new item. </p>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WMenuItem.html#a772f165f3dc02138c28d74f1f42d1a45" title="Creates a new item.">WMenuItem::WMenuItem(const WString&amp;, WWidget *, LoadPolicy)</a> </dd></dl>

</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="a38d7a0fa3581f34aa72c9fd4d1a6eaeb"></a><!-- doxytag: member="Wt::WSubMenuItem::activateSignal" ref="a38d7a0fa3581f34aa72c9fd4d1a6eaeb" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classWt_1_1SignalBase.html">SignalBase</a> &amp; Wt::WSubMenuItem::activateSignal </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [protected, virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns the signal used to activate the item. </p>
<p>The default implementation will tries to cast the <a class="el" href="classWt_1_1WMenuItem.html#a185b334943c3e07d63d3e45a17e960f7" title="Returns the widget that represents the item.">itemWidget()</a> or its first child if item is <a class="el" href="classWt_1_1WMenuItem.html#a59b6dee6c95ae958f0c3b76d5ef7272d">closeable</a> to a <a class="el" href="classWt_1_1WInteractWidget.html" title="An abstract widget that can receive user-interface interaction.">WInteractWidget</a> and returns the <a class="el" href="classWt_1_1WInteractWidget.html#ae11e050cce0d4a8f742afa3ef92bfe8c">clicked signal</a>. </p>

<p>Reimplemented from <a class="el" href="classWt_1_1WMenuItem.html#a5f1d03e160011fcd39759b681f8bc063">Wt::WMenuItem</a>.</p>

</div>
</div>
<a class="anchor" id="a3883ce17fd7d04553510700189fbc7af"></a><!-- doxytag: member="Wt::WSubMenuItem::createItemWidget" ref="a3883ce17fd7d04553510700189fbc7af" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classWt_1_1WWidget.html">WWidget</a> * Wt::WSubMenuItem::createItemWidget </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [protected, virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Creates the widget that represents the item. </p>
<p>The default implementation will return:</p>
<ul>
<li>a <a class="el" href="classWt_1_1WAnchor.html" title="A widget that represents an HTML anchor (to link to other documents).">WAnchor</a> if item is not closeable and enabled;</li>
<li>a <a class="el" href="classWt_1_1WText.html" title="A widget that renders (XHTML) text.">WText</a> if item is not closeable and disabled;</li>
<li>a <a class="el" href="classWt_1_1WContainerWidget.html" title="A widget that holds and manages child widgets.">WContainerWidget</a> with <a class="el" href="classWt_1_1WAnchor.html" title="A widget that represents an HTML anchor (to link to other documents).">WAnchor</a> or <a class="el" href="classWt_1_1WText.html" title="A widget that renders (XHTML) text.">WText</a> (the label of enabled or disabled item accordingly) and <a class="el" href="classWt_1_1WText.html" title="A widget that renders (XHTML) text.">WText</a> (the close icon) inside if item is closeable.</li>
</ul>
<p>A call to <a class="el" href="classWt_1_1WSubMenuItem.html#a3883ce17fd7d04553510700189fbc7af" title="Creates the widget that represents the item.">createItemWidget()</a> is immediately followed by <a class="el" href="classWt_1_1WSubMenuItem.html#a44820d1555db0e1f6593dd80d1c0b34e" title="Updates the widget that represents the item.">updateItemWidget()</a>.</p>
<p>If you reimplement this method, you should probably also reimplement <a class="el" href="classWt_1_1WSubMenuItem.html#a44820d1555db0e1f6593dd80d1c0b34e" title="Updates the widget that represents the item.">updateItemWidget()</a>. </p>

<p>Reimplemented from <a class="el" href="classWt_1_1WMenuItem.html#a5dd1286e97b110b621e00e02e58a15d2">Wt::WMenuItem</a>.</p>

</div>
</div>
<a class="anchor" id="af774d49f24f2ee362cc28eb688cb9eef"></a><!-- doxytag: member="Wt::WSubMenuItem::pathComponent" ref="af774d49f24f2ee362cc28eb688cb9eef" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">std::string Wt::WSubMenuItem::pathComponent </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns the path component for this item. </p>
<p>You may want to reimplement this to customize the path component set by the item in the application internal path.</p>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WMenuItem.html#a4291756303dbf128b718679cdb907a5a" title="Sets the path component for this item.">setPathComponent()</a></dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>the <code>path</code> component is UTF8 encoded (we may fix the API to use <a class="el" href="classWt_1_1WString.html" title="A value class which describes a locale-aware unicode string.">WString</a> in the future). </dd></dl>

<p>Reimplemented from <a class="el" href="classWt_1_1WMenuItem.html#a5ab0b5430b9fb852a45886deb0ff01b1">Wt::WMenuItem</a>.</p>

</div>
</div>
<a class="anchor" id="ad3096bef2abbc291cb2560cd16d92458"></a><!-- doxytag: member="Wt::WSubMenuItem::renderSelected" ref="ad3096bef2abbc291cb2560cd16d92458" args="(bool selected)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Wt::WSubMenuItem::renderSelected </td>
          <td>(</td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>selected</em></td><td>)</td>
          <td><code> [protected, virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Renders the item as selected or unselected. </p>
<p>The default implementation sets the styleclass for <a class="el" href="classWt_1_1WMenuItem.html#a185b334943c3e07d63d3e45a17e960f7" title="Returns the widget that represents the item.">itemWidget()</a> to 'item' for an unselected not closeable, 'itemselected' for selected not closeable, 'citem' for an unselected closeable and 'citemselected' for selected closeable item.</p>
<p>Note that this method is called from within a stateless slot implementation, and thus should be stateless as well. </p>

<p>Reimplemented from <a class="el" href="classWt_1_1WMenuItem.html#a3af62f2a97827c844e021ad2dd3f6085">Wt::WMenuItem</a>.</p>

</div>
</div>
<a class="anchor" id="a33eccd31a4aa8436cf66effa2cecf94b"></a><!-- doxytag: member="Wt::WSubMenuItem::setSubMenu" ref="a33eccd31a4aa8436cf66effa2cecf94b" args="(WMenu *subMenu)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Wt::WSubMenuItem::setSubMenu </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classWt_1_1WMenu.html">WMenu</a> *&#160;</td>
          <td class="paramname"><em>subMenu</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Sets a sub menu. </p>
<p>Ownership of the <code>subMenu</code> is transferred to the item. In most cases, the sub menu would use the same contents stack as the parent menu.</p>
<p>The default submenu is <code>0</code>, in which case the item behaves as a plain <a class="el" href="classWt_1_1WMenuItem.html" title="A single item in a menu.">WMenuItem</a>.</p>
<dl class="note"><dt><b>Note:</b></dt><dd>A sub menu can only be set before the item is added to a menu. </dd></dl>

</div>
</div>
<a class="anchor" id="aa30469d72bfdec0c85181f012e269e9f"></a><!-- doxytag: member="Wt::WSubMenuItem::subMenu" ref="aa30469d72bfdec0c85181f012e269e9f" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classWt_1_1WMenu.html">WMenu</a>* Wt::WSubMenuItem::subMenu </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns the sub menu. </p>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WSubMenuItem.html#a33eccd31a4aa8436cf66effa2cecf94b" title="Sets a sub menu.">setSubMenu()</a> </dd></dl>

</div>
</div>
<a class="anchor" id="a44820d1555db0e1f6593dd80d1c0b34e"></a><!-- doxytag: member="Wt::WSubMenuItem::updateItemWidget" ref="a44820d1555db0e1f6593dd80d1c0b34e" args="(WWidget *itemWidget)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Wt::WSubMenuItem::updateItemWidget </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classWt_1_1WWidget.html">WWidget</a> *&#160;</td>
          <td class="paramname"><em>itemWidget</em></td><td>)</td>
          <td><code> [protected, virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Updates the widget that represents the item. </p>
<p>The default implementation will cast the <code>itemWidget</code> to a <a class="el" href="classWt_1_1WAnchor.html" title="A widget that represents an HTML anchor (to link to other documents).">WAnchor</a>, and set the anchor's text and destination according to <a class="el" href="classWt_1_1WMenuItem.html#a2061c3c242e98e53c820bfa500db492c" title="Returns the text for this item.">text()</a> and <a class="el" href="classWt_1_1WSubMenuItem.html#af774d49f24f2ee362cc28eb688cb9eef" title="Returns the path component for this item.">pathComponent()</a>.</p>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WSubMenuItem.html#a3883ce17fd7d04553510700189fbc7af" title="Creates the widget that represents the item.">createItemWidget()</a> </dd></dl>

<p>Reimplemented from <a class="el" href="classWt_1_1WMenuItem.html#adf18031f469001bdd5333cff0a66a9a4">Wt::WMenuItem</a>.</p>

</div>
</div>
</div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Enumerator</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<hr size="1"><address style="text-align: right; margin: 3px"><small>
Generated on Fri Mar 30 2012 for <a href="http://www.webtoolkit.eu/wt">the
C++ Web Toolkit (Wt)</a> by&nbsp;<a
href="http://www.doxygen.org/index.html"><img src="doxygen.png"
alt="doxygen" border="0" style="vertical-align: middle; display:
inline-block; height: 2em"></a> 1.7.5.1</small></address>
</body>
</html>