1 write to Session
Microsoft.CodeAnalysis.EditorFeatures.Wpf (1)
InlineRename\UI\Adornment\RenameFlyoutViewModel.cs (1)
51Session = session;
36 references to Session
Microsoft.CodeAnalysis.EditorFeatures.Wpf (36)
InlineRename\UI\Adornment\RenameFlyoutViewModel.cs (33)
54Session.ReplacementTextChanged += OnReplacementTextChanged; 55Session.ReplacementsComputed += OnReplacementsComputed; 56Session.ReferenceLocationsChanged += OnReferenceLocationsChanged; 57Session.CommitStateChange += CommitStateChange; 60var smartRenameSession = smartRenameSessionFactory?.Value.CreateSmartRenameSession(Session.TriggerSpan); 70=> Visibility = this.Session.IsCommitInProgress ? Visibility.Collapsed : Visibility.Visible; 76get => Session.ReplacementText; 79if (value != Session.ReplacementText) 81Session.ApplyReplacementText(value, propagateEditImmediately: true, updateSelection: false); 91public bool AllowFileRename => Session.FileRenameInfo == InlineRenameFileRenameInfo.Allowed && _isReplacementTextValid; 92public bool ShowFileRename => Session.FileRenameInfo != InlineRenameFileRenameInfo.NotAllowed; 94public string FileRenameString => Session.FileRenameInfo switch 141get => Session.Options.RenameInComments; 145Session.RefreshRenameSessionWithOptionsChanged(Session.Options with { RenameInComments = value }); 151get => Session.Options.RenameInStrings; 155Session.RefreshRenameSessionWithOptionsChanged(Session.Options with { RenameInStrings = value }); 161get => Session.Options.RenameFile; 165Session.RefreshRenameSessionWithOptionsChanged(Session.Options with { RenameFile = value }); 171get => Session.PreviewChanges; 175Session.SetPreviewChanges(value); 181get => Session.Options.RenameOverloads; 185Session.RefreshRenameSessionWithOptionsChanged(Session.Options with { RenameOverloads = value }); 210=> !Session.MustRenameOverloads; 213=> Session.HasRenameOverloads; 232Session.InitiateCommit(); 239Session.Cancel(); 324Session.ReplacementTextChanged -= OnReplacementTextChanged; 325Session.ReplacementsComputed -= OnReplacementsComputed; 326Session.CommitStateChange -= CommitStateChange;
InlineRename\UI\SmartRename\SmartRenameViewModel.cs (3)
226var document = this.BaseViewModel.Session.TriggerDocument; 231var renameLocations = await this.BaseViewModel.Session.AllRenameLocationsTask.JoinAsync(cancellationToken) 233var context = await editorRenameService.GetRenameContextAsync(this.BaseViewModel.Session.RenameInfo, renameLocations, cancellationToken)