mirror of
https://github.com/Microsoft/vscode
synced 2024-10-04 02:14:06 +00:00
debug: fix auto attach not turning on if reselecting current state
Fixes https://github.com/microsoft/vscode/issues/111021
This commit is contained in:
parent
c70d984fa2
commit
63137db51c
|
@ -156,7 +156,7 @@ async function toggleAutoAttachSetting(context: vscode.ExtensionContext, scope?:
|
|||
|
||||
quickPick.show();
|
||||
|
||||
const result = await new Promise<PickResult>(resolve => {
|
||||
let result = await new Promise<PickResult>(resolve => {
|
||||
quickPick.onDidAccept(() => resolve(quickPick.selectedItems[0]));
|
||||
quickPick.onDidHide(() => resolve(undefined));
|
||||
quickPick.onDidTriggerButton(() => {
|
||||
|
@ -179,7 +179,11 @@ async function toggleAutoAttachSetting(context: vscode.ExtensionContext, scope?:
|
|||
}
|
||||
|
||||
if ('state' in result) {
|
||||
if (result.state !== current) {
|
||||
section.update(SETTING_STATE, result.state, scope);
|
||||
} else if (isTemporarilyDisabled) {
|
||||
result = { setTempDisabled: false };
|
||||
}
|
||||
}
|
||||
|
||||
if ('setTempDisabled' in result) {
|
||||
|
|
Loading…
Reference in a new issue