/// <summary> /// Increase the level of the section. /// </summary> public static void Move(SectionNode section) { SectionNode sibling = section.PrecedingSibling; section.Detach(); sibling.AppendChild(section); int children = section.SectionChildCount; for (int i = 0; i < children; ++i) { SectionNode child = section.SectionChild(0); child.Detach(); sibling.AppendChild(child); } }
/// <summary> /// Increase the level of the section. /// </summary> public static void Move(SectionNode section) { int index = section.Index + 1; SectionNode sibling = section.ParentAs <SectionNode>(); int children = sibling.SectionChildCount; for (int i = index; i < children; ++i) { SectionNode child = sibling.SectionChild(index); child.Detach(); section.AppendChild(child); } section.Detach(); sibling.ParentAs <ObiNode>().InsertAfter(section, sibling); }
/// <summary> /// Remove the section node. /// </summary> public override void UnExecute() { mNode.Detach(); base.UnExecute(); }