public override void Initialize() { _reportsViewerController = SdlTradosStudio.Application.GetController <ReportsViewerController>(); _reportsViewerController.ReportSelectionChanged += ReportsViewerController_ReportSelectionChanged; SetEnabled(); }
public SettingsViewModel(Window window, Settings settings, ImageService imageService, PathInfo pathInfo, ReportsViewerController controller, List <string> groupNames) { _window = window; _settings = settings; _pathInfo = pathInfo; _imageService = imageService; _controller = controller; _groupNames = groupNames; WindowTitle = "Settings"; DisplayDateSuffixWithReportName = settings.DisplayDateSuffixWithReportName; GroupType = GroupTypes.FirstOrDefault(a => a.Type == settings.GroupByType) ?? GroupTypes.First(); var reportTemplates = new List <ReportTemplate>(); foreach (var reportTemplate in _controller.GetCustomReportTemplates()) { if (!string.IsNullOrEmpty(reportTemplate.Path) && File.Exists(reportTemplate.Path)) { reportTemplate.IsAvailable = true; } reportTemplates.Add(reportTemplate); } _reportTemplates = new ObservableCollection <ReportTemplate>(reportTemplates); }
public override void Initialize() { _canEnable = true; _controller = SdlTradosStudio.Application.GetController <ReportsViewerController>(); SetEnabled(); }
public override void Initialize() { _canEnable = true; _pathInfo = new PathInfo(); _imageService = new ImageService(); _reportsViewerController = SdlTradosStudio.Application.GetController <ReportsViewerController>(); SetEnabled(); }
public override void Initialize() { _pathInfo = new PathInfo(); _imageService = new ImageService(); _reportsViewerController = SdlTradosStudio.Application.GetController<ReportsViewerController>(); _reportsViewerController.ReportSelectionChanged += ReportsViewerController_ReportSelectionChanged; SetEnabled(); }
public DataViewModel(List <Report> reports, ReportsViewerController reportViewerController) { Reports = reports; _reportViewerController = reportViewerController; }