/// <summary> /// Initializes a new instance of the <see cref="CustomLabelsVM"/> class /// with the list of custom labels and a label host. /// </summary> /// <param name="appsettings">The app setings.</param> /// <param name="labelService">The host for the labels.</param> /// <param name="dialogService">The dialog service</param> public CustomLabelsVM(IAppSettings appsettings, ICustomLabelService labelService, IDialogService dialogService) { _dialogService = dialogService; _customLabels = appsettings.CustomLabels; CustomLabels = new ObservableCollection <CustomLabelVM>(_customLabels.Select(customLabel => new CustomLabelVM(customLabel, dialogService))); _labelService = labelService; foreach (var customLabelVm in CustomLabels) { _labelService.AddCustomTextLabel(customLabelVm); } AddLabelCommand = new RelayCommand(AddLabelCommandOnExecute); RemoveLabelCommand = new RelayCommand <CustomLabelVM>(RemoveLabelCommandOnExecute); }
public OrdersController(IOrderService orderService, IOrderModelFactory orderModelFactory, ICustomLabelService customLabelService, OrderSettings orderSettings, IShipmentStatusHistoryService shipmentStatusHistoryService, IReturnRequestService returnRequestService, IReturnRequestModelFactory requestModelFactory, IOrderAccountant orderAccountant, IPdfService pdfService, IDownloadService downloadService, IOrderItemDownloadService orderItemDownloadService, IProductModelFactory productModelFactory) { _orderService = orderService; _orderModelFactory = orderModelFactory; _customLabelService = customLabelService; _orderSettings = orderSettings; _shipmentStatusHistoryService = shipmentStatusHistoryService; _returnRequestService = returnRequestService; _requestModelFactory = requestModelFactory; _orderAccountant = orderAccountant; _pdfService = pdfService; _downloadService = downloadService; _orderItemDownloadService = orderItemDownloadService; _productModelFactory = productModelFactory; }
/// <summary> /// Initializes a new instance of the <see cref="MainControl"/> class. /// Entry point. /// </summary> /// <param name="options">The deskband options.</param> /// <param name="info">The taskbar info.</param> /// <param name="track">The track model.</param> /// <param name="appsettings">The app settings</param> /// <param name="audiosourceMananger">The audio source manager</param> /// <param name="settingsWindow">The settings window.</param> /// <param name="labelService">The label service.</param> public MainControl( CSDeskBandOptions options, TaskbarInfo info, Track track, IAppSettings appsettings, IAudioSourceManager audiosourceMananger, ISettingsWindow settingsWindow, ICustomLabelService labelService) { InitializeComponent(); _uiDispatcher = Dispatcher.CurrentDispatcher; Options = options; TaskbarInfo = info; _appSettings = appsettings; _audioSourceManager = audiosourceMananger; _track = track; _settingsWindow = settingsWindow; _labelService = labelService; #pragma warning disable CS4014 Task.Run(InitializeAsync); #pragma warning restore CS4014 }
public CustomLabelsController(ICustomLabelService customLabelService, ICustomLabelModelFactory customLabelModelFactory) { _customLabelService = customLabelService; _customLabelModelFactory = customLabelModelFactory; }