diff options
author | Alexandru Dima <alexdima@microsoft.com> | 2019-03-06 12:44:56 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-06 12:44:56 +0300 |
commit | 507312a3e3b34b084b467dfd983263bc7c9d87e0 (patch) | |
tree | cba42485cafea7a09135b96a4d462bd97fdc796e /src/vs/base/browser/ui/menu/menubar.ts | |
parent | 5338ec73cb805739f4fa040f140387ccc8e1819e (diff) | |
parent | 988bbc777e7ded8435443c6902983d92b88a312d (diff) |
Merge pull request #69876 from sbatten/fix/698301.32.0
fix/69830
Diffstat (limited to 'src/vs/base/browser/ui/menu/menubar.ts')
-rw-r--r-- | src/vs/base/browser/ui/menu/menubar.ts | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/vs/base/browser/ui/menu/menubar.ts b/src/vs/base/browser/ui/menu/menubar.ts index 4506ec9f488..ca3ba9f3021 100644 --- a/src/vs/base/browser/ui/menu/menubar.ts +++ b/src/vs/base/browser/ui/menu/menubar.ts @@ -954,6 +954,16 @@ class ModifierKeyEmitter extends Emitter<IModifierKeyStatus> { this._keyStatus.lastKeyPressed = undefined; })); + this._subscriptions.push(domEvent(document.body, 'mouseup', true)(e => { + this._keyStatus.lastKeyPressed = undefined; + })); + + this._subscriptions.push(domEvent(document.body, 'mousemove', true)(e => { + if (e.buttons) { + this._keyStatus.lastKeyPressed = undefined; + } + })); + this._subscriptions.push(domEvent(window, 'blur')(e => { this._keyStatus.lastKeyPressed = undefined; this._keyStatus.lastKeyReleased = undefined; |