You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
204 lines
13 KiB
204 lines
13 KiB
<!-- HTML header for doxygen 1.8.13-->
|
|
<!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.14"/>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<title>QtMvvm: QtMvvm::Binding 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/searchdata.js"></script>
|
|
<script type="text/javascript" src="search/search.js"></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" style="display: inline;">
|
|
<tbody>
|
|
<tr style="height: 56px;">
|
|
<td id="projectalign" style="padding-left: 0.5em;">
|
|
<div id="projectname">QtMvvm
|
|
 <span id="projectnumber">1.1.0</span>
|
|
</div>
|
|
<div id="projectbrief">A mvvm oriented library for Qt, to create Projects for Widgets and Quick in parallel</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<a style="float: right;" target="_blank" href="https://github.com/Skycoder42/QtMvvm">
|
|
<img style="padding: 10px;" src="GitHub_Logo.png"/>
|
|
</a>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.8.14 -->
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
/* @license-end */
|
|
</script>
|
|
<script type="text/javascript" src="menudata.js"></script>
|
|
<script type="text/javascript" src="menu.js"></script>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
$(function() {
|
|
initMenu('',true,false,'search.php','Search');
|
|
$(document).ready(function() { init_search(); });
|
|
});
|
|
/* @license-end */</script>
|
|
<div id="main-nav"></div>
|
|
<!-- window showing the filter options -->
|
|
<div id="MSearchSelectWindow"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
</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 id="nav-path" class="navpath">
|
|
<ul>
|
|
<li class="navelem"><a class="el" href="namespace_qt_mvvm.html">QtMvvm</a></li><li class="navelem"><a class="el" href="class_qt_mvvm_1_1_binding.html">Binding</a></li> </ul>
|
|
</div>
|
|
</div><!-- top -->
|
|
<div class="header">
|
|
<div class="summary">
|
|
<a href="#pub-types">Public Types</a> |
|
|
<a href="#pub-methods">Public Member Functions</a> |
|
|
<a href="class_qt_mvvm_1_1_binding-members.html">List of all members</a> </div>
|
|
<div class="headertitle">
|
|
<div class="title">QtMvvm::Binding Class Reference</div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
|
|
<p>A handle to a multidirectional binding between properties.
|
|
<a href="class_qt_mvvm_1_1_binding.html#details">More...</a></p>
|
|
|
|
<p><code>#include <<a class="el" href="binding_8h_source.html">binding.h</a>></code></p>
|
|
<table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-types"></a>
|
|
Public Types</h2></td></tr>
|
|
<tr class="memitem:a6a03a1d2ac1775e202aa7ae65fb76315"><td class="memItemLeft" align="right" valign="top">enum  </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qt_mvvm_1_1_binding.html#a6a03a1d2ac1775e202aa7ae65fb76315">BindingDirectionFlag</a> { <a class="el" href="class_qt_mvvm_1_1_binding.html#a6a03a1d2ac1775e202aa7ae65fb76315ab4f4583ffedfaf5c9776d90ea7cb7ece">SingleInit</a> = 0x01,
|
|
<a class="el" href="class_qt_mvvm_1_1_binding.html#a6a03a1d2ac1775e202aa7ae65fb76315af6a94905cd1372ea564100ead04360b9">OneWayToView</a> = (0x02 | SingleInit),
|
|
<a class="el" href="class_qt_mvvm_1_1_binding.html#a6a03a1d2ac1775e202aa7ae65fb76315aa50e49b9b126b3dddd0278133312f100">OneWayToViewModel</a> = 0x04,
|
|
<a class="el" href="class_qt_mvvm_1_1_binding.html#a6a03a1d2ac1775e202aa7ae65fb76315a8248e753de211820e05f5b5e35ad9db8">TwoWay</a> = (OneWayToView | OneWayToViewModel)
|
|
}</td></tr>
|
|
<tr class="memdesc:a6a03a1d2ac1775e202aa7ae65fb76315"><td class="mdescLeft"> </td><td class="mdescRight">Flags to control how to bind the properties. <a href="class_qt_mvvm_1_1_binding.html#a6a03a1d2ac1775e202aa7ae65fb76315">More...</a><br /></td></tr>
|
|
<tr class="separator:a6a03a1d2ac1775e202aa7ae65fb76315"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><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:ad2adb445f984744db703b2554952b36e"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qt_mvvm_1_1_binding.html#ad2adb445f984744db703b2554952b36e">isValid</a> () const</td></tr>
|
|
<tr class="memdesc:ad2adb445f984744db703b2554952b36e"><td class="mdescLeft"> </td><td class="mdescRight">Specifies whether the binding is a valid and active binding. <a href="#ad2adb445f984744db703b2554952b36e">More...</a><br /></td></tr>
|
|
<tr class="separator:ad2adb445f984744db703b2554952b36e"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:abb9d7693a1be0de37fccedcd914f54f5"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qt_mvvm_1_1_binding.html#abb9d7693a1be0de37fccedcd914f54f5">operator bool</a> () const</td></tr>
|
|
<tr class="memdesc:abb9d7693a1be0de37fccedcd914f54f5"><td class="mdescLeft"> </td><td class="mdescRight">Specifies whether the binding is a valid and active binding. <a href="#abb9d7693a1be0de37fccedcd914f54f5">More...</a><br /></td></tr>
|
|
<tr class="separator:abb9d7693a1be0de37fccedcd914f54f5"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:abc595c43c2be664a66f9f178a4663b2a"><td class="memItemLeft" align="right" valign="top"><a id="abc595c43c2be664a66f9f178a4663b2a"></a>
|
|
Q_INVOKABLE void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qt_mvvm_1_1_binding.html#abc595c43c2be664a66f9f178a4663b2a">unbind</a> ()</td></tr>
|
|
<tr class="memdesc:abc595c43c2be664a66f9f178a4663b2a"><td class="mdescLeft"> </td><td class="mdescRight">Remove the binding by disconnecting all change signals. <br /></td></tr>
|
|
<tr class="separator:abc595c43c2be664a66f9f178a4663b2a"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table>
|
|
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
|
<div class="textblock"><p>A handle to a multidirectional binding between properties. </p>
|
|
<p>This class is returned by the <a class="el" href="namespace_qt_mvvm.html#affee350f1bec121b95759bb02a4df50f" title="Create a multidirectional binding between properties. ">bind()</a> function as a handle to a binding. It can be used to check if the binding is valid and can remove a binding again.</p>
|
|
<dl class="section note"><dt>Note</dt><dd>You don't need to keep the <a class="el" href="class_qt_mvvm_1_1_binding.html" title="A handle to a multidirectional binding between properties. ">Binding</a> as reference. The binding will stay even if you don't hold any references to it. This class serves as a passive watcher over a binding.</dd></dl>
|
|
<dl class="section see"><dt>See also</dt><dd><a class="el" href="namespace_qt_mvvm.html#affee350f1bec121b95759bb02a4df50f" title="Create a multidirectional binding between properties. ">QtMvvm::bind</a> </dd></dl>
|
|
|
|
<p class="definition">Definition at line <a class="el" href="binding_8h_source.html#l00014">14</a> of file <a class="el" href="binding_8h_source.html">binding.h</a>.</p>
|
|
</div><h2 class="groupheader">Member Enumeration Documentation</h2>
|
|
<a id="a6a03a1d2ac1775e202aa7ae65fb76315"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#a6a03a1d2ac1775e202aa7ae65fb76315">◆ </a></span>BindingDirectionFlag</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">enum <a class="el" href="class_qt_mvvm_1_1_binding.html#a6a03a1d2ac1775e202aa7ae65fb76315">QtMvvm::Binding::BindingDirectionFlag</a></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Flags to control how to bind the properties. </p>
|
|
<table class="fieldtable">
|
|
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><a id="a6a03a1d2ac1775e202aa7ae65fb76315ab4f4583ffedfaf5c9776d90ea7cb7ece"></a>SingleInit </td><td class="fielddoc"><p>Only initialize the view by settings it to the viewmodels value on creation. </p>
|
|
</td></tr>
|
|
<tr><td class="fieldname"><a id="a6a03a1d2ac1775e202aa7ae65fb76315af6a94905cd1372ea564100ead04360b9"></a>OneWayToView </td><td class="fielddoc"><p>All changes done to the viewmodel are propagated to the view. </p>
|
|
</td></tr>
|
|
<tr><td class="fieldname"><a id="a6a03a1d2ac1775e202aa7ae65fb76315aa50e49b9b126b3dddd0278133312f100"></a>OneWayToViewModel </td><td class="fielddoc"><p>All changes done to the view are propagated to the viewmodel. </p>
|
|
</td></tr>
|
|
<tr><td class="fieldname"><a id="a6a03a1d2ac1775e202aa7ae65fb76315a8248e753de211820e05f5b5e35ad9db8"></a>TwoWay </td><td class="fielddoc"><p>All changes on both sides are propagated to the other one. </p>
|
|
</td></tr>
|
|
</table>
|
|
|
|
<p class="definition">Definition at line <a class="el" href="binding_8h_source.html#l00020">20</a> of file <a class="el" href="binding_8h_source.html">binding.h</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<h2 class="groupheader">Member Function Documentation</h2>
|
|
<a id="ad2adb445f984744db703b2554952b36e"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#ad2adb445f984744db703b2554952b36e">◆ </a></span>isValid()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">QtMvvm::Binding::isValid </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td> const</td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Specifies whether the binding is a valid and active binding. </p>
|
|
<dl class="section return"><dt>Returns</dt><dd><code>true</code> If the binding is valid and active, <code>false</code> if invalid or already unbound</dd></dl>
|
|
<p>A binding is considered valid is if has successfully been set up and has not been unbound yet. A valid binding means view and viewModel are valid can the properties could be found.</p>
|
|
<dl class="section see"><dt>See also</dt><dd><a class="el" href="class_qt_mvvm_1_1_binding.html#abc595c43c2be664a66f9f178a4663b2a" title="Remove the binding by disconnecting all change signals. ">Binding::unbind</a>, <a class="el" href="namespace_qt_mvvm.html#affee350f1bec121b95759bb02a4df50f" title="Create a multidirectional binding between properties. ">bind()</a> </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="abb9d7693a1be0de37fccedcd914f54f5"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#abb9d7693a1be0de37fccedcd914f54f5">◆ </a></span>operator bool()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">QtMvvm::Binding::operator bool </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td> const</td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Specifies whether the binding is a valid and active binding. </p>
|
|
<dl class="section return"><dt>Returns</dt><dd><code>true</code> If the binding is valid and active, <code>false</code> if invalid or already unbound</dd></dl>
|
|
<p>A binding is considered valid is if has successfully been set up and has not been unbound yet. A valid binding means view and viewModel are valid can the properties could be found.</p>
|
|
<dl class="section see"><dt>See also</dt><dd><a class="el" href="class_qt_mvvm_1_1_binding.html#abc595c43c2be664a66f9f178a4663b2a" title="Remove the binding by disconnecting all change signals. ">Binding::unbind</a>, <a class="el" href="namespace_qt_mvvm.html#affee350f1bec121b95759bb02a4df50f" title="Create a multidirectional binding between properties. ">bind()</a> </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<hr/>The documentation for this class was generated from the following files:<ul>
|
|
<li><a class="el" href="binding_8h_source.html">binding.h</a></li>
|
|
<li>binding.dox</li>
|
|
</ul>
|
|
</div><!-- contents -->
|
|
<!-- start footer part -->
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated on Wed Aug 8 2018 19:15:45 for QtMvvm by  <a href="http://www.doxygen.org/index.html">
|
|
<img class="footer" src="doxygen.png" alt="doxygen"/>
|
|
</a> 1.8.14
|
|
</small></address>
|
|
</body>
|
|
</html>
|
|
|