public void Open(List <DateIntervalManager> managers, BoolManager boolManager) { ClearList(); foreach (var item in managers) { var presenter = new IntervalActionElementPresenter(item, elementPrefab, elementPrefab.height); presenter.OnTable += () => Presenter_OnTable(presenter); presenters.Add(presenter); } { var presenter = new BoolActionElementPresenter(boolManager, boolElementPrefab, boolElementPrefab.height); presenters.Add(presenter); } IsVisible = true; }
private void Presenter_OnTable(IntervalActionElementPresenter presenter) { Singleton <Manager> .Instance.OpenTable(presenter.manager); }