本文整理汇总了C#中CheckState.Equals方法的典型用法代码示例。如果您正苦于以下问题:C# CheckState.Equals方法的具体用法?C# CheckState.Equals怎么用?C# CheckState.Equals使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CheckState
的用法示例。
在下文中一共展示了CheckState.Equals方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SetCheckedParentNodes
private static void SetCheckedParentNodes(TreeListNode node, CheckState check)
{
if (node.ParentNode != null)
{
bool b = false;
for (int i = 0; i < node.ParentNode.Nodes.Count; i++)
{
CheckState state = node.ParentNode.Nodes[i].CheckState;
if (!check.Equals(state))
{
b = true;
break;
}
}
node.ParentNode.CheckState = b ? CheckState.Indeterminate : check;
SetCheckedParentNodes(node.ParentNode, check);
}
}
示例2: SetCheckedParentNodes
private void SetCheckedParentNodes(DevExpress.XtraTreeList.Nodes.TreeListNode node, CheckState check)
{
if (node.ParentNode != null)
{
bool b = false;
CheckState state;
for (int i = 0; i < node.ParentNode.Nodes.Count; i++)
{
if (node.ParentNode.Nodes[i].Tag == null) state = CheckState.Unchecked;
else state = (CheckState)node.ParentNode.Nodes[i].Tag;
if (!check.Equals(state))
{
b = !b;
break;
}
}
node.ParentNode.Tag = b ? CheckState.Indeterminate : check;
SetCheckedParentNodes(node.ParentNode, check);
}
}
示例3: SetCheckedParentNodes
private void SetCheckedParentNodes(TreeListNode node, CheckState check) {
if (node.ParentNode != null) {
bool b = false;
CheckState state;
for (int i = 0; i < node.ParentNode.Nodes.Count; i++) {
state = (CheckState)node.ParentNode.Nodes[i].CheckState;
if (!check.Equals(state)) {
b = !b;
break;
}
}
node.ParentNode.CheckState = b ? CheckState.Checked : check;
SetCheckedParentNodes(node.ParentNode, check);
}
}
示例4: SetCheckedParentNodes
private void SetCheckedParentNodes(IDictionary<string, List<Layer>> mapLayers, TreeListNode node, CheckState checkState)
{
if(node.ParentNode!=null)
{
var b = false;
CheckState state;
foreach (TreeListNode parentNode in node.ParentNode.Nodes)
{
if(parentNode.Tag==null)
{
state=CheckState.Unchecked;
}
else
{
state = (CheckState) parentNode.Tag;
}
if(!checkState.Equals(state))
{
b = !b;
break;
}
}
node.ParentNode.Tag = b ? CheckState.Indeterminate : checkState;
SetCheckedParentNodes(mapLayers, node.ParentNode, checkState);
}
}
示例5: SetCheckedParentNodes
private void SetCheckedParentNodes(TreeListNode node, CheckState checkState)
{
if (node.ParentNode != null)
{
bool b = false;
CheckState state;
for (int i = 0; i < node.ParentNode.Nodes.Count; i++)
{
state = (CheckState)node.ParentNode.Nodes[i].CheckState;
if (!checkState.Equals(state))
{
b = !b;
break;
}
}
node.ParentNode.CheckState = b ? CheckState.Indeterminate : checkState;
//SetRulesHistoryState(node.ParentNode["RuleName"].ToString(), node.ParentNode.Checked);
SetCheckedParentNodes(node.ParentNode, checkState);
}
}