Skip to content

Commit

Permalink
Merge pull request #147026 from microsoft/roblou/altActionEnablement
Browse files Browse the repository at this point in the history
Respect alt action precondition. Fix #147024
  • Loading branch information
roblourens committed Apr 7, 2022
2 parents b499467 + ecb3510 commit 6ea335e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/vs/platform/actions/browser/menuEntryActionViewItem.ts
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ export class MenuEntryActionViewItem extends ActionViewItem {
let alternativeKeyDown = this._altKey.keyStatus.altKey || ((isWindows || isLinux) && this._altKey.keyStatus.shiftKey);

const updateAltState = () => {
const wantsAltCommand = mouseOver && alternativeKeyDown;
const wantsAltCommand = mouseOver && alternativeKeyDown && !!this._commandAction.alt?.enabled;
if (wantsAltCommand !== this._wantsAltCommand) {
this._wantsAltCommand = wantsAltCommand;
this.updateLabel();
Expand Down

0 comments on commit 6ea335e

Please sign in to comment.