Skip to content

Commit

Permalink
Merge pull request #508 from X-Sharp/master
Browse files Browse the repository at this point in the history
QueryStatus is used to enable commands that are not enabled by defaul…
[release]
  • Loading branch information
madskristensen authored Aug 15, 2024
2 parents 2fac3c4 + 56480b6 commit 912c346
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,11 @@ public CommandInterceptor(CommandID cmd, Func<CommandProgression> func)

public int QueryStatus(ref Guid pguidCmdGroup, uint cCmds, OLECMD[] prgCmds, IntPtr pCmdText)
{
if (prgCmds[0].cmdID == _cmd.ID)
{
prgCmds[0].cmdf = (uint)OLECMDF.OLECMDF_ENABLED | (uint)OLECMDF.OLECMDF_SUPPORTED;
return VSConstants.S_OK;
}
return (int)Microsoft.VisualStudio.OLE.Interop.Constants.OLECMDERR_E_NOTSUPPORTED;
}

Expand Down

0 comments on commit 912c346

Please sign in to comment.