We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6225605 commit 2ea779cCopy full SHA for 2ea779c
src/toolkit/Community.VisualStudio.Toolkit.Shared/Debugger/Debugger.cs
@@ -1,6 +1,5 @@
1
using System;
2
using System.Threading.Tasks;
3
-using Microsoft.VisualStudio;
4
using Microsoft.VisualStudio.Shell;
5
using Microsoft.VisualStudio.Shell.Interop;
6
@@ -40,10 +39,7 @@ public async Task<DebugMode> GetDebugModeAsync()
40
39
{
41
await ThreadHelper.JoinableTaskFactory.SwitchToMainThreadAsync();
42
43
- IVsDebugger debugger = await VS.Services.GetDebuggerAsync();
44
- DBGMODE[] mode = new DBGMODE[1];
45
- ErrorHandler.ThrowOnFailure(debugger.GetMode(mode));
46
- DBGMODE dbgMode = mode[0] & ~DBGMODE.DBGMODE_EncMask;
+ DBGMODE dbgMode = VsShellUtilities.GetDebugMode(ServiceProvider.GlobalProvider) & ~DBGMODE.DBGMODE_EncMask;
47
48
return dbgMode switch
49
0 commit comments