public TagAggregator(TagAggregatorFactoryService factory, ITextView textView, IBufferGraph bufferGraph, TagAggregatorOptions options) { this.TagAggregatorFactoryService = factory; this.textView = textView; this.BufferGraph = bufferGraph; this.options = options; this.joinableTaskHelper = new JoinableTaskHelper(factory.JoinableTaskContext); if (textView != null) { textView.Closed += this.OnTextView_Closed; } taggers = new Dictionary <ITextBuffer, IList <ITagger <T> > >(); uniqueTaggers = new List <Tuple <ITagger <T>, int> >(); if (((TagAggregatorOptions2)options).HasFlag(TagAggregatorOptions2.DeferTaggerCreation)) { this.joinableTaskHelper.RunOnUIThread((Action)(this.EnsureInitialized)); } else { this.Initialize(); } this.BufferGraph.GraphBufferContentTypeChanged += new EventHandler <GraphBufferContentTypeChangedEventArgs>(BufferGraph_GraphBufferContentTypeChanged); this.BufferGraph.GraphBuffersChanged += new EventHandler <GraphBuffersChangedEventArgs>(BufferGraph_GraphBuffersChanged); }
public TagAggregator(TagAggregatorFactoryService factory, ITextView textView, IBufferGraph bufferGraph, TagAggregatorOptions options) { this.TagAggregatorFactoryService = factory; this.textView = textView; this.BufferGraph = bufferGraph; this.options = options; this.joinableTaskHelper = new JoinableTaskHelper(factory.JoinableTaskContext); if (textView != null) { textView.Closed += this.OnTextView_Closed; } if (((TagAggregatorOptions2)options).HasFlag(TagAggregatorOptions2.DeferTaggerCreation)) { this.joinableTaskHelper.RunOnUIThread((Action)(this.EnsureInitialized)); } else { this.Initialize(); } }