Split codeQL.goto command

This commit is contained in:
Nora
2023-05-08 12:15:07 +00:00
parent bf9eb2469b
commit b6df591329
3 changed files with 12 additions and 1 deletions

View File

@@ -828,6 +828,11 @@
"title": "CodeQL: Go to QL Code",
"enablement": "codeql.hasQLSource"
},
{
"command": "codeQL.gotoQLContextEditor",
"title": "CodeQL: Go to QL Code",
"enablement": "codeql.hasQLSource"
},
{
"command": "codeQL.openDataExtensionsEditor",
"title": "CodeQL: Open Data Extensions Editor"
@@ -1466,6 +1471,10 @@
{
"command": "codeQLTests.acceptOutputContextTestItem",
"when": "false"
},
{
"command": "codeQL.gotoQLContextEditor",
"when": "false"
}
],
"editor/context": [
@@ -1514,7 +1523,7 @@
"when": "resourceExtname == .qhelp && isWorkspaceTrusted"
},
{
"command": "codeQL.gotoQL",
"command": "codeQL.gotoQLContextEditor",
"when": "editorLangId == ql-summary && config.codeQL.canary"
}
]

View File

@@ -299,6 +299,7 @@ export type EvalLogViewerCommands = {
export type SummaryLanguageSupportCommands = {
"codeQL.gotoQL": () => Promise<void>;
"codeQL.gotoQLContextEditor": () => Promise<void>;
};
export type TestUICommands = {

View File

@@ -78,6 +78,7 @@ export class SummaryLanguageSupport extends DisposableObject {
public getCommands(): SummaryLanguageSupportCommands {
return {
"codeQL.gotoQL": this.handleGotoQL.bind(this),
"codeQL.gotoQLContextEditor": this.handleGotoQL.bind(this),
};
}