public GotoBraceCommand(ITextView textView, ITextBuffer textBuffer) :
            base(textView, _commands, false) {
            var importComposer = new ContentTypeImportComposer<IBraceMatcherProvider>(EditorShell.Current.CompositionService);
            _braceMatcherProvider = importComposer.GetImport(textBuffer.ContentType.TypeName);

            TextBuffer = textBuffer;
        }
Beispiel #2
0
        public GotoBraceCommand(ITextView textView, ITextBuffer textBuffer, IServiceContainer services) :
            base(textView, _commands, false)
        {
            var locator = services.GetService <IContentTypeServiceLocator>();

            _braceMatcherProvider = locator.GetService <IBraceMatcherProvider>(textBuffer.ContentType.TypeName);
            TextBuffer            = textBuffer;
        }
Beispiel #3
0
        public GotoBraceCommand(ITextView textView, ITextBuffer textBuffer) :
            base(textView, _commands, false)
        {
            var importComposer = new ContentTypeImportComposer <IBraceMatcherProvider>(EditorShell.Current.CompositionService);

            _braceMatcherProvider = importComposer.GetImport(textBuffer.ContentType.TypeName);

            TextBuffer = textBuffer;
        }
Beispiel #4
0
        public GotoBraceCommand(ITextView textView, ITextBuffer textBuffer, ICoreShell shell) :
            base(textView, _commands, false)
        {
            var importComposer = new ContentTypeImportComposer <IBraceMatcherProvider>(shell.GetService <ICompositionService>());

            _braceMatcherProvider = importComposer.GetImport(textBuffer.ContentType.TypeName);

            TextBuffer = textBuffer;
        }