private void ShowUnchecked(string view) { Logger.Info(CultureInfo.InvariantCulture, "Showing Output window (selected view: \"{0}\").", SelectedView); if (string.IsNullOrEmpty(view)) { view = DefaultView; } SelectedView = view; if (TextEditor != null) { TextEditor.TextArea.Caret.Offset = TextEditor.Document.TextLength; TextEditor.ScrollToEnd(); } _editor.ActivateItem(this); }
private void GoToLocation() { var selectedItem = SelectedItem; if (selectedItem == null) { return; } var command = selectedItem.GoToLocationCommand; if (command != null && command.CanExecute(SelectedItem)) { command.Execute(SelectedItem); return; } // Find the document that contains the location string. var documentService = _editor.Services.GetInstance <IDocumentService>(); if (documentService == null) { return; } var location = selectedItem.Location; foreach (var document in documentService.Documents) { if (document.IsUntitled && document.UntitledName.IndexOf(location, StringComparison.OrdinalIgnoreCase) >= 0 || !document.IsUntitled && document.Uri.LocalPath.IndexOf(location, StringComparison.OrdinalIgnoreCase) >= 0) { var vm = document.ViewModels.FirstOrDefault(); if (vm != null) { _editor.ActivateItem(vm); break; } } } }