private List <SectionNode> GetSectionsList(urakawa.core.TreeNode rNode) //sdk2 :used treenode instead of rootnode { List <SectionNode> sectionsList = new List <SectionNode> (); m_FirstPageNumberedPhraseOfFirstSection = null; rNode.AcceptDepthFirst( delegate(urakawa.core.TreeNode n) { if (n is SectionNode) { if (!((SectionNode)n).Used) { return(false); } sectionsList.Add((SectionNode)n); m_NextSectionPageAdjustmentDictionary.Add((SectionNode)n, null); } else if (n is EmptyNode && ((EmptyNode)n).Used && ((EmptyNode)n).Index == 0 && ((EmptyNode)n).Role_ == EmptyNode.Role.Page) { if (sectionsList.Count >= 2) { m_NextSectionPageAdjustmentDictionary[sectionsList[sectionsList.Count - 2]] = (EmptyNode)n; } if (sectionsList.Count == 1) { m_FirstPageNumberedPhraseOfFirstSection = (EmptyNode)n; } } return(true); }, delegate(urakawa.core.TreeNode n) { }); return(sectionsList); }