Terraria v1.4.4.9
Terraria source code documentation
All Classes Namespaces Files Functions Variables Enumerations Enumerator Properties Events Macros

◆ GetPreviousContentSibling()

static bool MS.Internal.Xml.Cache.XPathNodeHelper.GetPreviousContentSibling ( ref XPathNode[] pageNode,
ref int idxNode )
inlinestatic

Definition at line 211 of file XPathNodeHelper.cs.

212 {
213 int num = idxNode;
214 num = pageNode[num].GetParent(out var pageNode2);
215 if (num != 0)
216 {
217 int num2 = idxNode - 1;
218 XPathNode[] array;
219 if (num2 == 0)
220 {
221 array = pageNode[0].PageInfo.PreviousPage;
222 num2 = array.Length - 1;
223 }
224 else
225 {
226 array = pageNode;
227 }
228 if (num == num2 && pageNode2 == array)
229 {
230 return false;
231 }
232 XPathNode[] pageNode3 = array;
233 int num3 = num2;
234 do
235 {
236 array = pageNode3;
237 num2 = num3;
238 num3 = pageNode3[num3].GetParent(out pageNode3);
239 }
240 while (num3 != num || pageNode3 != pageNode2);
241 if (array[num2].NodeType != XPathNodeType.Attribute)
242 {
243 pageNode = array;
244 idxNode = num2;
245 return true;
246 }
247 }
248 return false;
249 }

References MS.Internal.Xml.Cache.XPathNode.GetParent().

Referenced by MS.Internal.Xml.Cache.XPathDocumentNavigator.MoveToPrevious().