Ejemplo n.º 1
0
        public void UpdateColorScheme()
        {
            var reportResults = (DataSource as BindingListSource)?.ReportResults as ClusteredReportResults;

            if (reportResults == null)
            {
                ReportColorScheme = null;
            }
            else
            {
                ReportColorScheme = ReportColorScheme.FromClusteredResults(CancellationToken.None, reportResults);
            }
        }
Ejemplo n.º 2
0
        private Tuple <Clusterer, ClusteredReportResults, ReportColorScheme> GetClusteredResultsBackground(ILongWaitBroker longWaitBroker)
        {
            var clusterer = Clusterer.CreateClusterer(longWaitBroker.CancellationToken, BindingListSource.ClusteringSpec ?? ClusteringSpec.DEFAULT,
                                                      BindingListSource.ReportResults);

            if (clusterer == null)
            {
                return(null);
            }

            var results     = clusterer.GetClusteredResults();
            var colorScheme = ReportColorScheme.FromClusteredResults(longWaitBroker.CancellationToken, results);

            return(Tuple.Create(clusterer, results, colorScheme));
        }