static void OnControllerChanged(BindableObject b, BindableLayoutController oldC, BindableLayoutController newC) { if (oldC != null) { oldC.ItemsSource = null; } if (newC == null) { return; } newC.StartBatchUpdate(); newC.ItemsSource = GetItemsSource(b); newC.ItemTemplate = GetItemTemplate(b); newC.ItemTemplateSelector = GetItemTemplateSelector(b); newC.EmptyView = GetEmptyView(b); newC.EmptyViewTemplate = GetEmptyViewTemplate(b); newC.EndBatchUpdate(); }
static void SetBindableLayoutController(BindableObject b, BindableLayoutController value) { b.SetValue(BindableLayoutControllerProperty, value); }