提交 0b0a068c 编写于 作者: N Nat Ayewah 提交者: Ravi Chande

Keep PreviewPaneService.cs

This reverts commit 64b95c62.
上级 1f4221b0
...@@ -18,18 +18,20 @@ ...@@ -18,18 +18,20 @@
using Microsoft.VisualStudio.Imaging.Interop; using Microsoft.VisualStudio.Imaging.Interop;
using Microsoft.VisualStudio.LanguageServices.Implementation.Utilities; using Microsoft.VisualStudio.LanguageServices.Implementation.Utilities;
using Microsoft.VisualStudio.Shell; using Microsoft.VisualStudio.Shell;
using IVsUIShell = Microsoft.VisualStudio.Shell.Interop.IVsUIShell;
using SVsUIShell = Microsoft.VisualStudio.Shell.Interop.SVsUIShell;
namespace Microsoft.VisualStudio.LanguageServices.Implementation.PreviewPane namespace Microsoft.VisualStudio.LanguageServices.Implementation.PreviewPane
{ {
[ExportWorkspaceServiceFactory(typeof(IPreviewPaneService), ServiceLayer.Host), Shared] [ExportWorkspaceServiceFactory(typeof(IPreviewPaneService), ServiceLayer.Host), Shared]
internal class PreviewPaneService : ForegroundThreadAffinitizedObject, IPreviewPaneService, IWorkspaceServiceFactory internal class PreviewPaneService : ForegroundThreadAffinitizedObject, IPreviewPaneService, IWorkspaceServiceFactory
{ {
private readonly EnvDTE.DTE _dte; private readonly IVsUIShell _uiShell;
[ImportingConstructor] [ImportingConstructor]
public PreviewPaneService(SVsServiceProvider serviceProvider) public PreviewPaneService(SVsServiceProvider serviceProvider)
{ {
_dte = serviceProvider.GetService(typeof(EnvDTE.DTE)) as EnvDTE.DTE; _uiShell = serviceProvider.GetService(typeof(SVsUIShell)) as IVsUIShell;
} }
IWorkspaceService IWorkspaceServiceFactory.CreateService(HostWorkspaceServices workspaceServices) IWorkspaceService IWorkspaceServiceFactory.CreateService(HostWorkspaceServices workspaceServices)
...@@ -107,7 +109,7 @@ private static Uri GetHelpLink(DiagnosticData diagnostic, string language, strin ...@@ -107,7 +109,7 @@ private static Uri GetHelpLink(DiagnosticData diagnostic, string language, strin
return new PreviewPane( return new PreviewPane(
severityIcon: null, id: null, title: null, description: null, helpLink: null, helpLinkToolTipText: null, severityIcon: null, id: null, title: null, description: null, helpLink: null, helpLinkToolTipText: null,
previewContent: previewContent, logIdVerbatimInTelemetry: false, dte: _dte); previewContent: previewContent, logIdVerbatimInTelemetry: false, uiShell: _uiShell);
} }
var helpLinkToolTipText = string.Empty; var helpLinkToolTipText = string.Empty;
...@@ -128,7 +130,7 @@ private static Uri GetHelpLink(DiagnosticData diagnostic, string language, strin ...@@ -128,7 +130,7 @@ private static Uri GetHelpLink(DiagnosticData diagnostic, string language, strin
helpLinkToolTipText: helpLinkToolTipText, helpLinkToolTipText: helpLinkToolTipText,
previewContent: previewContent, previewContent: previewContent,
logIdVerbatimInTelemetry: diagnostic.CustomTags.Contains(WellKnownDiagnosticTags.Telemetry), logIdVerbatimInTelemetry: diagnostic.CustomTags.Contains(WellKnownDiagnosticTags.Telemetry),
dte: _dte, uiShell: _uiShell,
optionPageGuid: optionPageGuid); optionPageGuid: optionPageGuid);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册