public void TextViewCreated(IWpfTextView textView) { if (!_hasLoaded) LoadSettings(); ITextDocument document; if (TextDocumentFactoryService.TryGetTextDocument(textView.TextDataModel.DocumentBuffer, out document)) { string fileName = Path.GetFileName(document.FilePath).ToLowerInvariant(); if (string.IsNullOrEmpty(fileName) || !_map.ContainsKey(fileName)) return; LogoAdornment highlighter = new LogoAdornment(textView, _map[fileName], _isVisible, _initOpacity); } }
public void TextViewCreated(IWpfTextView textView) { if (!_hasLoaded) { LoadSettings(); } ITextDocument document; if (TextDocumentFactoryService.TryGetTextDocument(textView.TextDataModel.DocumentBuffer, out document)) { string fileName = Path.GetFileName(document.FilePath).ToLowerInvariant(); if (string.IsNullOrEmpty(fileName) || !_map.ContainsKey(fileName)) { return; } LogoAdornment highlighter = new LogoAdornment(textView, _map[fileName], _isVisible, _initOpacity); } }