Beispiel #1
0
        protected override IListViewSource CreateListViewSource()
        {
            _scrollToHideManager = new OrgEventScrollToHideUIManager(
                VenuesAndShowsTableView, ListSettingsView);

            var tableSource = new OrgEventTableSource(VenuesAndShowsTableView,
                                                      ViewModel, _scrollToHideManager);

            this.CreateBinding(tableSource)
            .For(ts => ts.ItemsSource)
            .To <OrgEventViewModel>(vm => vm.ListItems)
            .WithConversion(new OrgEventTableSourceConverter(), ViewModel)
            .Apply();

            return(tableSource);
        }
Beispiel #2
0
        private void InitializeSearch()
        {
            var searchBarDelegate = new OrgEventSearchBarDelegate(SearchBar, ViewModel);

            SearchBar.Delegate = searchBarDelegate;

            var searchTableSource =
                new OrgEventTableSource(SearchTableView, ViewModel);

            this.CreateBinding(searchTableSource)
            .For(ts => ts.ItemsSource)
            .To <OrgEventViewModel>(vm => vm.SearchListItems)
            .WithConversion(new OrgEventTableSourceConverter(), ViewModel)
            .Apply();

            SearchTableView.Source = searchTableSource;
        }