예제 #1
0
파일: Node.cs 프로젝트: ZachPerkitny/redc
        /// <summary>
        ///
        /// </summary>
        /// <param name="node"></param>
        /// <param name="child"></param>
        /// <returns></returns>
        private Node PreInsert(Node node, Node child)
        {
            // Reference: https://www.w3.org/TR/2015/REC-dom-20151119/#concept-node-pre-insert
            EnsurePreInsertionValidity(node, child);

            if (node == child)
            {
                child = node.NextSibling;
            }

            OwnerDocument.AdoptNode(node);
            Insert(node, child);
            return(node);
        }