diff --git a/src/LanguageServer/Protocol/Microsoft.CodeAnalysis.LanguageServer.Protocol.csproj b/src/LanguageServer/Protocol/Microsoft.CodeAnalysis.LanguageServer.Protocol.csproj index cd1328b0bab7f..f34e515575b44 100644 --- a/src/LanguageServer/Protocol/Microsoft.CodeAnalysis.LanguageServer.Protocol.csproj +++ b/src/LanguageServer/Protocol/Microsoft.CodeAnalysis.LanguageServer.Protocol.csproj @@ -71,18 +71,17 @@ - - - - + + - - - + + + + diff --git a/src/VisualStudio/CodeLens/Microsoft.VisualStudio.LanguageServices.CodeLens.csproj b/src/VisualStudio/CodeLens/Microsoft.VisualStudio.LanguageServices.CodeLens.csproj index 43bc7dc630c3d..0f58e2bf74514 100644 --- a/src/VisualStudio/CodeLens/Microsoft.VisualStudio.LanguageServices.CodeLens.csproj +++ b/src/VisualStudio/CodeLens/Microsoft.VisualStudio.LanguageServices.CodeLens.csproj @@ -12,7 +12,7 @@ - + diff --git a/src/VisualStudio/CodeLens/ReferenceCodeLensProvider.cs b/src/VisualStudio/CodeLens/ReferenceCodeLensProvider.cs index ce16ca3322ac9..b25720be9c198 100644 --- a/src/VisualStudio/CodeLens/ReferenceCodeLensProvider.cs +++ b/src/VisualStudio/CodeLens/ReferenceCodeLensProvider.cs @@ -12,8 +12,8 @@ using Microsoft.CodeAnalysis; using Microsoft.CodeAnalysis.CodeLens; using Microsoft.CodeAnalysis.Editor; +using Microsoft.CodeAnalysis.Editor.Wpf; using Microsoft.CodeAnalysis.Host.Mef; -using Microsoft.CodeAnalysis.LanguageServer; using Microsoft.VisualStudio.Core.Imaging; using Microsoft.VisualStudio.Language.CodeLens; using Microsoft.VisualStudio.Language.CodeLens.Remoting; @@ -104,7 +104,7 @@ private async Task PollForUpdatesAsync() var projectVersions = await _lazyCodeLensCallbackService.Value.InvokeAsync>( this, - "GetProjectVersionsAsync", + nameof(ICodeLensContext.GetProjectVersionsAsync), [keys], _cancellationTokenSource.Token).ConfigureAwait(false); @@ -200,7 +200,7 @@ public void Dispose() // raw data from Roslyn OOP such as razor find all reference results var referenceCountOpt = await _callbackService.InvokeAsync( _owner, - "GetReferenceCountAsync", + nameof(ICodeLensContext.GetReferenceCountAsync), [Descriptor, descriptorContext, _calculatedReferenceCount], cancellationToken).ConfigureAwait(false); @@ -243,7 +243,7 @@ public async Task GetDetailsAsync(CodeLensDescriptorC // raw data from Roslyn OOP such as razor find all reference results var referenceLocationDescriptors = await _callbackService.InvokeAsync<(string projectVersion, ImmutableArray references)?>( _owner, - "FindReferenceLocationsAsync", + nameof(ICodeLensContext.FindReferenceLocationsAsync), [Descriptor, descriptorContext], cancellationToken).ConfigureAwait(false); @@ -263,8 +263,8 @@ public async Task GetDetailsAsync(CodeLensDescriptorC ImageId imageId = default; if (referenceLocationDescriptor.Glyph.HasValue) { - var imageData = referenceLocationDescriptor.Glyph.Value.GetVsImageData(); - imageId = new ImageId(imageData.guid, imageData.id); + var moniker = referenceLocationDescriptor.Glyph.Value.GetImageMoniker(); + imageId = new ImageId(moniker.Guid, moniker.Id); } return new CodeLensDetailEntryDescriptor()