public ReportCatalogControl(IReportCatalogViewModel viewModel, Brush textColor)
        {
            _textColor = textColor;
            InitializeComponent();
            DataContext = viewModel;
            LoadingText.Foreground = textColor;
            ErrorText.Foreground = textColor;

            viewModel.PropertyChanged += (s, e) =>
                {
                    if(e.PropertyName == "Items")
                    {
                        RecurseItems(viewModel.Items, CatalogTree.Items);
                    }
                };
        }
Exemple #2
0
        public ReportCatalogControl(IReportCatalogViewModel viewModel, Brush textColor)
        {
            _textColor = textColor;
            InitializeComponent();
            DataContext            = viewModel;
            LoadingText.Foreground = textColor;
            ErrorText.Foreground   = textColor;

            viewModel.PropertyChanged += (s, e) =>
            {
                if (e.PropertyName == "Items")
                {
                    RecurseItems(viewModel.Items, CatalogTree.Items);
                }
            };
        }
 protected virtual ReportCatalogControl CreateReportCatalogControl(
     IReportCatalogViewModel reportCatalogItemViewModel)
 {
     return(new ReportCatalogControl(reportCatalogItemViewModel, new SolidColorBrush(TextColor)));
 }
 protected virtual ReportCatalogControl CreateReportCatalogControl(
     IReportCatalogViewModel reportCatalogItemViewModel)
 {
     return new ReportCatalogControl(reportCatalogItemViewModel, new SolidColorBrush(TextColor));
 }