public ClipboardListViewModel( IAction[] allActions, IClipboardUserInterfaceMediator clipboardUserInterfaceMediator, // ReSharper disable once SuggestBaseTypeForParameter IKeyInterceptor hotkeyInterceptor, IAsyncListDictionaryBinder <IClipboardDataControlPackage, IAction> packageActionBinder, IAsyncFilter asyncFilter, IPerformanceHandleFactory performanceHandleFactory, IUserInterfaceThread userInterfaceThread) { Elements = new ObservableCollection <IClipboardDataControlPackage>(); Actions = new ObservableCollection <IAction>(); Actions.CollectionChanged += Actions_CollectionChanged; var pasteAction = allActions.OfType <IPasteAction>() .Single(); this.allActions = allActions.Where(x => x != pasteAction) .ToArray(); this.clipboardUserInterfaceMediator = clipboardUserInterfaceMediator; this.packageActionBinder = packageActionBinder; this.asyncFilter = asyncFilter; this.performanceHandleFactory = performanceHandleFactory; this.userInterfaceThread = userInterfaceThread; PreparePackageBinder(pasteAction); RegisterMediatorEvents(clipboardUserInterfaceMediator); RegisterKeyEvents(hotkeyInterceptor); }
public LinkParser( IFileTypeInterpreter fileTypeInterpreter, IDomainNameResolver domainNameResolver, IAsyncFilter asyncFilter, IPerformanceHandleFactory performanceHandleFactory) { this.fileTypeInterpreter = fileTypeInterpreter; this.domainNameResolver = domainNameResolver; this.asyncFilter = asyncFilter; this.performanceHandleFactory = performanceHandleFactory; }