예제 #1
0
        void OnSelectionChanged(SelectionChangedArgs selectionChangedArgs)
        {
            var dataSourceListView = DataSourceListView((IModelListView)selectionChangedArgs.DashboardViewItemModel.View);

            if (dataSourceListView != null)
            {
                var dashboardViewItems = View.Items.OfType <DashboardViewItem>();
                foreach (var dashboardViewItem in dashboardViewItems)
                {
                    var modelDashboardViewItemEx = (IModelDashboardViewItemEx)dashboardViewItem.GetModel(View);
                    if (modelDashboardViewItemEx.Filter.DataSourceView == dataSourceListView.Model)
                    {
                        var listViewFiltering = new ListViewFilteringArgs(dashboardViewItem, modelDashboardViewItemEx, dataSourceListView);
                        OnListViewFiltering(listViewFiltering);
                        if (!listViewFiltering.Handled)
                        {
                            var filterListView = FilteredListView(dataSourceListView, dashboardViewItem, modelDashboardViewItemEx);
                            if (filterListView != null)
                            {
                                OnListViewFiltered(new ListViewFilteredArgs(filterListView));
                            }
                        }
                    }
                }
            }
            NotifyControllers(selectionChangedArgs.ListView);
        }
예제 #2
0
        void OnListViewFiltering(ListViewFilteringArgs e)
        {
            EventHandler <ListViewFilteringArgs> handler = ListViewFiltering;

            if (handler != null)
            {
                handler(this, e);
            }
        }
예제 #3
0
        void OnListViewFiltering(ListViewFilteringArgs e)
        {
            EventHandler <ListViewFilteringArgs> handler = ListViewFiltering;

            handler?.Invoke(this, e);
        }