本文整理汇总了C#中Behaviac.Design.NodeViewData.SetSubItem方法的典型用法代码示例。如果您正苦于以下问题:C# NodeViewData.SetSubItem方法的具体用法?C# NodeViewData.SetSubItem怎么用?C# NodeViewData.SetSubItem使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Behaviac.Design.NodeViewData
的用法示例。
在下文中一共展示了NodeViewData.SetSubItem方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: MoveSubItem
private bool MoveSubItem(NodeViewData sourceNvd, NodeViewData targetNvd, NodeViewData.SubItemAttachment sourceAttachment, NodeViewData.SubItemAttachment targetAttachment, bool insertPreviously, bool isCopied) {
if (sourceNvd != null && targetNvd != null && sourceAttachment != null &&
sourceNvd.SetSubItem(targetNvd, sourceAttachment, targetAttachment, insertPreviously, isCopied)) {
// set the prefab dirty for the node
if (!string.IsNullOrEmpty(sourceNvd.Node.PrefabName)) {
sourceNvd.Node.HasOwnPrefabData = true;
}
if (!string.IsNullOrEmpty(targetNvd.Node.PrefabName)) {
targetNvd.Node.HasOwnPrefabData = true;
}
SelectedNode = targetNvd;
// call the ClickEvent event handler
if (ClickEvent != null) {
ClickEvent(SelectedNode);
}
UndoManager.Save(this.RootNode);
LayoutChanged();
return true;
}
return false;
}
示例2: MoveSubItem
private bool MoveSubItem(NodeViewData nvd, NodeViewData.SubItemAttachment sourceAttachment, NodeViewData.SubItemAttachment targetAttachment, bool insertPreviously)
{
if (nvd != null && sourceAttachment != null && targetAttachment != null &&
nvd.SetSubItem(nvd, targetAttachment, sourceAttachment, insertPreviously))
{
// set the prefab dirty for the current node
if (!string.IsNullOrEmpty(nvd.Node.PrefabName))
{
nvd.Node.HasOwnPrefabData = true;
}
UndoManager.Save(this.RootNode, nvd.Node.Behavior);
return true;
}
return false;
}