public SizePerservingFillContainer() { children.Add(content = new CompositeDrawable()); content .Layout(0, 0, targetSize.x, targetSize.y) .Anchor(Align.Center, 0, 0) .Pivot(Align.Center, 0, 0); }
static void AddDrawNodeSubtreeRecur(int index, CompositeDrawable parentDrawable, List <DrawNode> drawNodes) { for (int i = 0, end = parentDrawable.children.Count; i < end; i++) { var child = parentDrawable.children[i]; var compositeChild = child as CompositeDrawable; if (compositeChild != null && parentDrawable.flattenSubtree) { AddDrawNodeSubtreeRecur(index, compositeChild, drawNodes); } else { drawNodes.Add(child.GenerateDrawNodeSubtree(index)); } } }