public XamlTextViewCreationListener( [Import(typeof(SVsServiceProvider))] IServiceProvider serviceProvider, IVsEditorAdaptersFactoryService adapterService, AnalysisEntryService entryService ) { _serviceProvider = serviceProvider; AdapterService = adapterService; _entryService = entryService; }
public ExpansionClient(ITextView textView, IVsEditorAdaptersFactoryService adapterFactory, IServiceProvider serviceProvider) { _textView = textView; _serviceProvider = serviceProvider; _adapterFactory = adapterFactory; _view = _adapterFactory.GetViewAdapter(_textView); _lines = (IVsTextLines)_adapterFactory.GetBufferAdapter(_textView.TextBuffer); _expansion = _lines as IVsExpansion; if (_expansion == null) { throw new ArgumentException("TextBuffer does not support expansions"); } _entryService = serviceProvider.GetEntryService(); }