public IFluentGuiBuilder <TChild> Row <TChild>(Func <T, TChild> getChild) { var row = new FluentTableRowControl <TChild>(onChildLayoutChanged, () => getChild(getObject())); addRow(row); return(row.Build()); }
public void Update() { var oldCount = itemObjects.Count; itemObjects.Clear(); itemObjects.AddRange(getObject()); if (rows.Count < itemObjects.Count) { for (var i = rows.Count; i < itemObjects.Count; i++) { var iLoc = i; var row = new FluentTableRowControl <T>(OnChildLayoutChanged, () => itemObjects[iLoc]); // TODO fill the row with controls rows.Add(row); } } foreach (var row in rows.Take(itemObjects.Count)) { row.Update(); } if (itemObjects.Count != oldCount) { RebuildEto(); } }