mirror of
https://github.com/taigrr/arduinolibs
synced 2025-01-18 04:33:12 -08:00
494 lines
33 KiB
HTML
494 lines
33 KiB
HTML
<!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"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
<meta name="generator" content="Doxygen 1.8.6"/>
|
|
<title>ArduinoLibs: Form Class Reference</title>
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="jquery.js"></script>
|
|
<script type="text/javascript" src="dynsections.js"></script>
|
|
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="search/search.js"></script>
|
|
<script type="text/javascript">
|
|
$(document).ready(function() { searchBox.OnSelectItem(0); });
|
|
</script>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
</head>
|
|
<body>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<div id="titlearea">
|
|
<table cellspacing="0" cellpadding="0">
|
|
<tbody>
|
|
<tr style="height: 56px;">
|
|
<td style="padding-left: 0.5em;">
|
|
<div id="projectname">ArduinoLibs
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.8.6 -->
|
|
<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 Page</span></a></li>
|
|
<li><a href="pages.html"><span>Related Pages</span></a></li>
|
|
<li><a href="modules.html"><span>Modules</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 List</span></a></li>
|
|
<li><a href="classes.html"><span>Class Index</span></a></li>
|
|
<li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li>
|
|
<li><a href="functions.html"><span>Class Members</span></a></li>
|
|
</ul>
|
|
</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"> </span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark"> </span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark"> </span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark"> </span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark"> </span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark"> </span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark"> </span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark"> </span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark"> </span>Groups</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark"> </span>Pages</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>
|
|
|
|
</div><!-- top -->
|
|
<div class="header">
|
|
<div class="summary">
|
|
<a href="#pub-methods">Public Member Functions</a> |
|
|
<a href="#friends">Friends</a> |
|
|
<a href="classForm-members.html">List of all members</a> </div>
|
|
<div class="headertitle">
|
|
<div class="title">Form Class Reference</div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
|
|
<p>Manager for a form containing data input/output fields.
|
|
<a href="classForm.html#details">More...</a></p>
|
|
|
|
<p><code>#include <<a class="el" href="Form_8h_source.html">Form.h</a>></code></p>
|
|
<table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
|
|
Public Member Functions</h2></td></tr>
|
|
<tr class="memitem:ad30836b22edde707a52d94090b716996"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#ad30836b22edde707a52d94090b716996">Form</a> (LiquidCrystal &lcd)</td></tr>
|
|
<tr class="memdesc:ad30836b22edde707a52d94090b716996"><td class="mdescLeft"> </td><td class="mdescRight">Constructs a new form and associates it with <em>lcd</em>. <a href="#ad30836b22edde707a52d94090b716996">More...</a><br/></td></tr>
|
|
<tr class="separator:ad30836b22edde707a52d94090b716996"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a9cda7cce41e81bfaca51e922d4f9b98f"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a9cda7cce41e81bfaca51e922d4f9b98f"></a>
|
|
 </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#a9cda7cce41e81bfaca51e922d4f9b98f">~Form</a> ()</td></tr>
|
|
<tr class="memdesc:a9cda7cce41e81bfaca51e922d4f9b98f"><td class="mdescLeft"> </td><td class="mdescRight">Detaches all remaining fields and destroys this form. <br/></td></tr>
|
|
<tr class="separator:a9cda7cce41e81bfaca51e922d4f9b98f"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a89bd3850e87caa2ca7b2e946f923d0ee"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#a89bd3850e87caa2ca7b2e946f923d0ee">dispatch</a> (int event)</td></tr>
|
|
<tr class="memdesc:a89bd3850e87caa2ca7b2e946f923d0ee"><td class="mdescLeft"> </td><td class="mdescRight">Dispatches <em>event</em> to the currently active field using <a class="el" href="classField.html#a061bd1ed4d8b079df86465df8facd3b3" title="Dispatches event via this field. ">Field::dispatch()</a>. <a href="#a89bd3850e87caa2ca7b2e946f923d0ee">More...</a><br/></td></tr>
|
|
<tr class="separator:a89bd3850e87caa2ca7b2e946f923d0ee"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a788a186ea4a7ebd75283a948ca45f4d1"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#a788a186ea4a7ebd75283a948ca45f4d1">nextField</a> ()</td></tr>
|
|
<tr class="memdesc:a788a186ea4a7ebd75283a948ca45f4d1"><td class="mdescLeft"> </td><td class="mdescRight">Changes to the next field in the "tab order". <a href="#a788a186ea4a7ebd75283a948ca45f4d1">More...</a><br/></td></tr>
|
|
<tr class="separator:a788a186ea4a7ebd75283a948ca45f4d1"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:acb080fe4f4631e9060e6efab8eaa0a90"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#acb080fe4f4631e9060e6efab8eaa0a90">prevField</a> ()</td></tr>
|
|
<tr class="memdesc:acb080fe4f4631e9060e6efab8eaa0a90"><td class="mdescLeft"> </td><td class="mdescRight">Changes to the previous field in the "tab order". <a href="#acb080fe4f4631e9060e6efab8eaa0a90">More...</a><br/></td></tr>
|
|
<tr class="separator:acb080fe4f4631e9060e6efab8eaa0a90"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:aba75b59f68b31dd77dbbac9ab5c3124b"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#aba75b59f68b31dd77dbbac9ab5c3124b">defaultField</a> ()</td></tr>
|
|
<tr class="memdesc:aba75b59f68b31dd77dbbac9ab5c3124b"><td class="mdescLeft"> </td><td class="mdescRight">Changes to default field (i.e., the first field). <a href="#aba75b59f68b31dd77dbbac9ab5c3124b">More...</a><br/></td></tr>
|
|
<tr class="separator:aba75b59f68b31dd77dbbac9ab5c3124b"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a5cb056ace428e75e321610555bfecac7"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#a5cb056ace428e75e321610555bfecac7">addField</a> (<a class="el" href="classField.html">Field</a> *field)</td></tr>
|
|
<tr class="memdesc:a5cb056ace428e75e321610555bfecac7"><td class="mdescLeft"> </td><td class="mdescRight">Adds <em>field</em> to this form. <a href="#a5cb056ace428e75e321610555bfecac7">More...</a><br/></td></tr>
|
|
<tr class="separator:a5cb056ace428e75e321610555bfecac7"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a7abd717029f9b19ee7318470072cd697"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#a7abd717029f9b19ee7318470072cd697">removeField</a> (<a class="el" href="classField.html">Field</a> *field)</td></tr>
|
|
<tr class="memdesc:a7abd717029f9b19ee7318470072cd697"><td class="mdescLeft"> </td><td class="mdescRight">Removes <em>field</em> from this form. <a href="#a7abd717029f9b19ee7318470072cd697">More...</a><br/></td></tr>
|
|
<tr class="separator:a7abd717029f9b19ee7318470072cd697"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a85a219a73294cef1f89a2182b5c25bf8"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classField.html">Field</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#a85a219a73294cef1f89a2182b5c25bf8">currentField</a> () const </td></tr>
|
|
<tr class="memdesc:a85a219a73294cef1f89a2182b5c25bf8"><td class="mdescLeft"> </td><td class="mdescRight">Returns the current field that is displayed on-screen. <a href="#a85a219a73294cef1f89a2182b5c25bf8">More...</a><br/></td></tr>
|
|
<tr class="separator:a85a219a73294cef1f89a2182b5c25bf8"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ae6004fedfa07191ffd47d7b12370b4e5"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#ae6004fedfa07191ffd47d7b12370b4e5">setCurrentField</a> (<a class="el" href="classField.html">Field</a> *field)</td></tr>
|
|
<tr class="memdesc:ae6004fedfa07191ffd47d7b12370b4e5"><td class="mdescLeft"> </td><td class="mdescRight">Sets the current <em>field</em> that is displayed on-screen. <a href="#ae6004fedfa07191ffd47d7b12370b4e5">More...</a><br/></td></tr>
|
|
<tr class="separator:ae6004fedfa07191ffd47d7b12370b4e5"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a48fb77f93e77b28b0397b59e1e9bf789"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#a48fb77f93e77b28b0397b59e1e9bf789">isCurrent</a> (<a class="el" href="classField.html">Field</a> &field) const </td></tr>
|
|
<tr class="memdesc:a48fb77f93e77b28b0397b59e1e9bf789"><td class="mdescLeft"> </td><td class="mdescRight">Returns true if <em>field</em> is currently displayed on-screen, false otherwise. <a href="#a48fb77f93e77b28b0397b59e1e9bf789">More...</a><br/></td></tr>
|
|
<tr class="separator:a48fb77f93e77b28b0397b59e1e9bf789"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a9e8d718ab55a8034c22c606ccfa90d65"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#a9e8d718ab55a8034c22c606ccfa90d65">show</a> ()</td></tr>
|
|
<tr class="memdesc:a9e8d718ab55a8034c22c606ccfa90d65"><td class="mdescLeft"> </td><td class="mdescRight">Shows the form, or does nothing if the form is already on-screen. <a href="#a9e8d718ab55a8034c22c606ccfa90d65">More...</a><br/></td></tr>
|
|
<tr class="separator:a9e8d718ab55a8034c22c606ccfa90d65"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a88b9146a3f68e837c5e831203096f9e9"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#a88b9146a3f68e837c5e831203096f9e9">hide</a> ()</td></tr>
|
|
<tr class="memdesc:a88b9146a3f68e837c5e831203096f9e9"><td class="mdescLeft"> </td><td class="mdescRight">Hides the form, or does nothing if the form is not on-screen. <a href="#a88b9146a3f68e837c5e831203096f9e9">More...</a><br/></td></tr>
|
|
<tr class="separator:a88b9146a3f68e837c5e831203096f9e9"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a3101f288e3e5aa8307c57f35861ad587"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classForm.html#a3101f288e3e5aa8307c57f35861ad587">isVisible</a> () const </td></tr>
|
|
<tr class="memdesc:a3101f288e3e5aa8307c57f35861ad587"><td class="mdescLeft"> </td><td class="mdescRight">Returns true if the form is shown; false if the form is hidden. <a href="#a3101f288e3e5aa8307c57f35861ad587">More...</a><br/></td></tr>
|
|
<tr class="separator:a3101f288e3e5aa8307c57f35861ad587"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="friends"></a>
|
|
Friends</h2></td></tr>
|
|
<tr class="memitem:aaec47a26a3c11c1debd3ed922b69cbd2"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aaec47a26a3c11c1debd3ed922b69cbd2"></a>
|
|
class </td><td class="memItemRight" valign="bottom"><b>Field</b></td></tr>
|
|
<tr class="separator:aaec47a26a3c11c1debd3ed922b69cbd2"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table>
|
|
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
|
<div class="textblock"><p>Manager for a form containing data input/output fields. </p>
|
|
<p>See the <a class="el" href="lcd_form.html">Form example</a> for more information on creating an application that uses forms and fields. </p>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8h_source.html#l00032">32</a> of file <a class="el" href="Form_8h_source.html">Form.h</a>.</p>
|
|
</div><h2 class="groupheader">Constructor & Destructor Documentation</h2>
|
|
<a class="anchor" id="ad30836b22edde707a52d94090b716996"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="mlabels">
|
|
<tr>
|
|
<td class="mlabels-left">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">Form::Form </td>
|
|
<td>(</td>
|
|
<td class="paramtype">LiquidCrystal & </td>
|
|
<td class="paramname"><em>lcd</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
<td class="mlabels-right">
|
|
<span class="mlabels"><span class="mlabel">explicit</span></span> </td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Constructs a new form and associates it with <em>lcd</em>. </p>
|
|
<p>This constructor is typically followed by calls to construct <a class="el" href="classField.html" title="Manages a single data input/output field within a Form. ">Field</a> values for each of the fields on the form. For example:</p>
|
|
<div class="fragment"><div class="line"><a class="code" href="classForm.html">Form</a> mainForm(lcd);</div>
|
|
<div class="line"><a class="code" href="classTextField.html">TextField</a> welcomeField(mainForm, <span class="stringliteral">"Form example"</span>, <span class="stringliteral">"v1.0"</span>);</div>
|
|
</div><!-- fragment --><div class="image">
|
|
<img src="FormText.png" alt="FormText.png"/>
|
|
</div>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8cpp_source.html#l00047">47</a> of file <a class="el" href="Form_8cpp_source.html">Form.cpp</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<h2 class="groupheader">Member Function Documentation</h2>
|
|
<a class="anchor" id="a5cb056ace428e75e321610555bfecac7"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void Form::addField </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classField.html">Field</a> * </td>
|
|
<td class="paramname"><em>field</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Adds <em>field</em> to this form. </p>
|
|
<p>Usually this function is not required because the field's constructor will add the field to the form automatically.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classForm.html#a7abd717029f9b19ee7318470072cd697" title="Removes field from this form. ">removeField()</a> </dd></dl>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8cpp_source.html#l00165">165</a> of file <a class="el" href="Form_8cpp_source.html">Form.cpp</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a85a219a73294cef1f89a2182b5c25bf8"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="mlabels">
|
|
<tr>
|
|
<td class="mlabels-left">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="classField.html">Field</a> * Form::currentField </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td> const</td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
<td class="mlabels-right">
|
|
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Returns the current field that is displayed on-screen. </p>
|
|
<p>Returns null if the form has no fields, or <a class="el" href="classForm.html#ae6004fedfa07191ffd47d7b12370b4e5" title="Sets the current field that is displayed on-screen. ">setCurrentField()</a> explicitly set the current field to null.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classForm.html#ae6004fedfa07191ffd47d7b12370b4e5" title="Sets the current field that is displayed on-screen. ">setCurrentField()</a>, <a class="el" href="classForm.html#a48fb77f93e77b28b0397b59e1e9bf789" title="Returns true if field is currently displayed on-screen, false otherwise. ">isCurrent()</a> </dd></dl>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8h_source.html#l00046">46</a> of file <a class="el" href="Form_8h_source.html">Form.h</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="aba75b59f68b31dd77dbbac9ab5c3124b"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void Form::defaultField </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Changes to default field (i.e., the first field). </p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classForm.html#a788a186ea4a7ebd75283a948ca45f4d1" title="Changes to the next field in the "tab order". ">nextField()</a>, <a class="el" href="classForm.html#acb080fe4f4631e9060e6efab8eaa0a90" title="Changes to the previous field in the "tab order". ">prevField()</a>, <a class="el" href="classForm.html#a85a219a73294cef1f89a2182b5c25bf8" title="Returns the current field that is displayed on-screen. ">currentField()</a> </dd></dl>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8cpp_source.html#l00152">152</a> of file <a class="el" href="Form_8cpp_source.html">Form.cpp</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a89bd3850e87caa2ca7b2e946f923d0ee"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">int Form::dispatch </td>
|
|
<td>(</td>
|
|
<td class="paramtype">int </td>
|
|
<td class="paramname"><em>event</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Dispatches <em>event</em> to the currently active field using <a class="el" href="classField.html#a061bd1ed4d8b079df86465df8facd3b3" title="Dispatches event via this field. ">Field::dispatch()</a>. </p>
|
|
<p>The <em>event</em> is usually obtained from <a class="el" href="classLCD.html#ac1e80e2603bd1cf0276c36092c416292" title="Gets the next button press, release, or idle event. ">LCD::getButton()</a>.</p>
|
|
<p>Returns zero if the <em>event</em> has been handled and no further action is required.</p>
|
|
<p>Returns FORM_CHANGED if one of the fields on the form has changed value due to the <em>event</em>, perhaps requiring the application to take further action based on the new field value. Use <a class="el" href="classForm.html#a85a219a73294cef1f89a2182b5c25bf8" title="Returns the current field that is displayed on-screen. ">currentField()</a> or <a class="el" href="classForm.html#a48fb77f93e77b28b0397b59e1e9bf789" title="Returns true if field is currently displayed on-screen, false otherwise. ">isCurrent()</a> to determine which field has changed.</p>
|
|
<div class="fragment"><div class="line"><span class="keywordtype">int</span> <span class="keyword">event</span> = lcd.<a class="code" href="classLCD.html#ac1e80e2603bd1cf0276c36092c416292">getButton</a>();</div>
|
|
<div class="line"><span class="keywordflow">if</span> (mainForm.dispatch(event) == FORM_CHANGED) {</div>
|
|
<div class="line"> <span class="keywordflow">if</span> (mainForm.isCurrent(volumeField)) {</div>
|
|
<div class="line"> <span class="comment">// Adjust the volume to match the field.</span></div>
|
|
<div class="line"> setVolume(volumeField.value());</div>
|
|
<div class="line"> }</div>
|
|
<div class="line">}</div>
|
|
</div><!-- fragment --><p>This function handles the Left and Right buttons to navigate between fields.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classField.html#a061bd1ed4d8b079df86465df8facd3b3" title="Dispatches event via this field. ">Field::dispatch()</a>, <a class="el" href="classLCD.html#ac1e80e2603bd1cf0276c36092c416292" title="Gets the next button press, release, or idle event. ">LCD::getButton()</a>, <a class="el" href="classForm.html#a85a219a73294cef1f89a2182b5c25bf8" title="Returns the current field that is displayed on-screen. ">currentField()</a>, <a class="el" href="classForm.html#a48fb77f93e77b28b0397b59e1e9bf789" title="Returns true if field is currently displayed on-screen, false otherwise. ">isCurrent()</a> </dd></dl>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8cpp_source.html#l00099">99</a> of file <a class="el" href="Form_8cpp_source.html">Form.cpp</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a88b9146a3f68e837c5e831203096f9e9"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void Form::hide </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Hides the form, or does nothing if the form is not on-screen. </p>
|
|
<p>The screen will be cleared to remove the contents of the current field.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classForm.html#a9e8d718ab55a8034c22c606ccfa90d65" title="Shows the form, or does nothing if the form is already on-screen. ">show()</a>, <a class="el" href="classForm.html#a3101f288e3e5aa8307c57f35861ad587" title="Returns true if the form is shown; false if the form is hidden. ">isVisible()</a> </dd></dl>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8cpp_source.html#l00293">293</a> of file <a class="el" href="Form_8cpp_source.html">Form.cpp</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a48fb77f93e77b28b0397b59e1e9bf789"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="mlabels">
|
|
<tr>
|
|
<td class="mlabels-left">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">bool Form::isCurrent </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classField.html">Field</a> & </td>
|
|
<td class="paramname"><em>field</em></td><td>)</td>
|
|
<td> const</td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
<td class="mlabels-right">
|
|
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Returns true if <em>field</em> is currently displayed on-screen, false otherwise. </p>
|
|
<p>This function is typically called after <a class="el" href="classForm.html#a89bd3850e87caa2ca7b2e946f923d0ee" title="Dispatches event to the currently active field using Field::dispatch(). ">dispatch()</a> returns FORM_CHANGED to determine which field has changed.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classForm.html#a85a219a73294cef1f89a2182b5c25bf8" title="Returns the current field that is displayed on-screen. ">currentField()</a>, <a class="el" href="classForm.html#ae6004fedfa07191ffd47d7b12370b4e5" title="Sets the current field that is displayed on-screen. ">setCurrentField()</a> </dd></dl>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8h_source.html#l00049">49</a> of file <a class="el" href="Form_8h_source.html">Form.h</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a3101f288e3e5aa8307c57f35861ad587"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="mlabels">
|
|
<tr>
|
|
<td class="mlabels-left">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">bool Form::isVisible </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td> const</td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
<td class="mlabels-right">
|
|
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Returns true if the form is shown; false if the form is hidden. </p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classForm.html#a9e8d718ab55a8034c22c606ccfa90d65" title="Shows the form, or does nothing if the form is already on-screen. ">show()</a>, <a class="el" href="classForm.html#a88b9146a3f68e837c5e831203096f9e9" title="Hides the form, or does nothing if the form is not on-screen. ">hide()</a> </dd></dl>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8h_source.html#l00053">53</a> of file <a class="el" href="Form_8h_source.html">Form.h</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a788a186ea4a7ebd75283a948ca45f4d1"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void Form::nextField </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Changes to the next field in the "tab order". </p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classForm.html#acb080fe4f4631e9060e6efab8eaa0a90" title="Changes to the previous field in the "tab order". ">prevField()</a>, <a class="el" href="classForm.html#aba75b59f68b31dd77dbbac9ab5c3124b" title="Changes to default field (i.e., the first field). ">defaultField()</a>, <a class="el" href="classForm.html#a85a219a73294cef1f89a2182b5c25bf8" title="Returns the current field that is displayed on-screen. ">currentField()</a> </dd></dl>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8cpp_source.html#l00118">118</a> of file <a class="el" href="Form_8cpp_source.html">Form.cpp</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="acb080fe4f4631e9060e6efab8eaa0a90"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void Form::prevField </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Changes to the previous field in the "tab order". </p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classForm.html#a788a186ea4a7ebd75283a948ca45f4d1" title="Changes to the next field in the "tab order". ">nextField()</a>, <a class="el" href="classForm.html#aba75b59f68b31dd77dbbac9ab5c3124b" title="Changes to default field (i.e., the first field). ">defaultField()</a>, <a class="el" href="classForm.html#a85a219a73294cef1f89a2182b5c25bf8" title="Returns the current field that is displayed on-screen. ">currentField()</a> </dd></dl>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8cpp_source.html#l00135">135</a> of file <a class="el" href="Form_8cpp_source.html">Form.cpp</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a7abd717029f9b19ee7318470072cd697"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void Form::removeField </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classField.html">Field</a> * </td>
|
|
<td class="paramname"><em>field</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Removes <em>field</em> from this form. </p>
|
|
<p>If <em>field</em> is the current field on-screen, then either the next or previous field will be made current.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classForm.html#a5cb056ace428e75e321610555bfecac7" title="Adds field to this form. ">addField()</a> </dd></dl>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8cpp_source.html#l00187">187</a> of file <a class="el" href="Form_8cpp_source.html">Form.cpp</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="ae6004fedfa07191ffd47d7b12370b4e5"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void Form::setCurrentField </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classField.html">Field</a> * </td>
|
|
<td class="paramname"><em>field</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Sets the current <em>field</em> that is displayed on-screen. </p>
|
|
<p>Use this function to programmatically force the form to display a specific field on-screen.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classForm.html#a85a219a73294cef1f89a2182b5c25bf8" title="Returns the current field that is displayed on-screen. ">currentField()</a>, <a class="el" href="classForm.html#a48fb77f93e77b28b0397b59e1e9bf789" title="Returns true if field is currently displayed on-screen, false otherwise. ">isCurrent()</a> </dd></dl>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8cpp_source.html#l00230">230</a> of file <a class="el" href="Form_8cpp_source.html">Form.cpp</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="a9e8d718ab55a8034c22c606ccfa90d65"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void Form::show </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Shows the form, or does nothing if the form is already on-screen. </p>
|
|
<p>When the form is shown, the screen will be cleared and the <a class="el" href="classForm.html#a85a219a73294cef1f89a2182b5c25bf8" title="Returns the current field that is displayed on-screen. ">currentField()</a> will be drawn.</p>
|
|
<p>If the form was previously hidden, then the field that was previously current will be shown again. Call <a class="el" href="classForm.html#aba75b59f68b31dd77dbbac9ab5c3124b" title="Changes to default field (i.e., the first field). ">defaultField()</a> before <a class="el" href="classForm.html#a9e8d718ab55a8034c22c606ccfa90d65" title="Shows the form, or does nothing if the form is already on-screen. ">show()</a> to reset the form to show the first field instead.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classForm.html#a88b9146a3f68e837c5e831203096f9e9" title="Hides the form, or does nothing if the form is not on-screen. ">hide()</a>, <a class="el" href="classForm.html#a3101f288e3e5aa8307c57f35861ad587" title="Returns true if the form is shown; false if the form is hidden. ">isVisible()</a>, <a class="el" href="classForm.html#aba75b59f68b31dd77dbbac9ab5c3124b" title="Changes to default field (i.e., the first field). ">defaultField()</a> </dd></dl>
|
|
|
|
<p>Definition at line <a class="el" href="Form_8cpp_source.html#l00274">274</a> of file <a class="el" href="Form_8cpp_source.html">Form.cpp</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<hr/>The documentation for this class was generated from the following files:<ul>
|
|
<li><a class="el" href="Form_8h_source.html">Form.h</a></li>
|
|
<li><a class="el" href="Form_8cpp_source.html">Form.cpp</a></li>
|
|
</ul>
|
|
</div><!-- contents -->
|
|
<!-- start footer part -->
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated on Wed Apr 1 2015 16:36:10 for ArduinoLibs by  <a href="http://www.doxygen.org/index.html">
|
|
<img class="footer" src="doxygen.png" alt="doxygen"/>
|
|
</a> 1.8.6
|
|
</small></address>
|
|
</body>
|
|
</html>
|