public TranslationAggregatorViewModel(TranslationManager translationManager) { _translations = new LinkedList <AggregatedTranslationViewModel>(); Manager = translationManager; Height = 100; // TODO: Get from config Width = 400; // TODO: Get from config AllTranslators = translationManager.AllEndpoints .Select(x => new TranslatorViewModel(x)) .ToList(); AvailableTranslators = AllTranslators .Where(x => x.Endpoint.Error == null) .ToList(); }
public TranslationAggregatorViewModel(TranslationManager translationManager) { _translations = new LinkedList <AggregatedTranslationViewModel>(); _saveHeightAndWidth = new DebounceFunction(1, SaveHeightAndWidth); Manager = translationManager; Height = Settings.Height; Width = Settings.Width; AllTranslators = translationManager.AllEndpoints .Select(x => new TranslatorViewModel(x)) .ToList(); AvailableTranslators = AllTranslators .Where(x => x.Endpoint.Error == null) .ToList(); }