Fix keyboard events not reaching web content in BrowserView#303799
Open
u9g wants to merge 2 commits intomicrosoft:mainfrom
Open
Fix keyboard events not reaching web content in BrowserView#303799u9g wants to merge 2 commits intomicrosoft:mainfrom
u9g wants to merge 2 commits intomicrosoft:mainfrom
Conversation
The before-input-event handler in tryHandleCommand was intercepting all arrow key + modifier combinations (Cmd+Arrow, Option+Arrow, etc.) and routing them to vscode's command system instead of letting them pass through to web content. This broke standard text navigation in the built-in browser: Cmd+Arrow for line start/end, Option+Arrow for word navigation, Option+Shift+Arrow for word selection, etc. Let all arrow key events pass through to web content unconditionally.
Enter was classified as a "non-editing key" in tryHandleCommand, causing it to be intercepted and routed to vscode's command system instead of being delivered to web page input handlers. This broke typing in text inputs, forms, and editors (e.g. Monaco) within the built-in browser. Remove Enter from the non-editing key list so it passes through to web content.
Contributor
|
U guys had full on plan to fooking make me suicide……send the money u
withdrawn from the fooking console…..
…On Sun, 22 Mar 2026 at 04:38 u9g ***@***.***> wrote:
tryHandleCommand in BrowserView's before-input-event handler intercepts
keyboard events too aggressively, preventing them from reaching web content
in the built-in browser.
*Arrow keys with modifiers* (Cmd+Arrow, Option+Arrow, Option+Shift+Arrow,
etc.) are routed to VS Code's command system instead of passing through for
standard text navigation. On macOS this means Cmd+Left/Right (line
start/end), Option+Left/Right (word navigation), and
Option+Shift+Left/Right (word selection) are all broken in web pages loaded
in the built-in browser.
*Enter* is classified as a "non-editing key", causing it to be
intercepted rather than delivered to web page input handlers. This breaks
typing in text inputs, forms, and editors (e.g. Monaco) within the built-in
browser.
Fix
- Let all arrow key events pass through to web content
unconditionally, since they are standard text navigation keys
- Remove Enter from the isNonEditingKey list so it reaches web content
------------------------------
You can view, comment on, or merge this pull request online at:
#303799
Commit Summary
- dd33c97
<dd33c97>
Fix arrow key events not reaching web content in BrowserView
- ed0608e
<ed0608e>
Fix Enter key not reaching web content in BrowserView
File Changes
(1 file <https://github.com/microsoft/vscode/pull/303799/files>)
- *M* src/vs/platform/browserView/electron-main/browserView.ts
<https://github.com/microsoft/vscode/pull/303799/files#diff-40ec9f5a0ecc43419ebf10b8d9cba3bc1cd982741e40e802ee220d9dc42b83b6>
(9)
Patch Links:
- https://github.com/microsoft/vscode/pull/303799.patch
- https://github.com/microsoft/vscode/pull/303799.diff
—
Reply to this email directly, view it on GitHub
<#303799?email_source=notifications&email_token=B5DU6GLP23WIMSYJKCSZ2CT4R4YWNA5CNFSNUABEM5UWIORPF5TWS5BNNB2WEL2QOVWGYUTFOF2WK43UF4ZTIMRZHAYTINJXG6THEZLBONXW5KTTOVRHGY3SNFRGKZFFMV3GK3TUVRTG633UMVZF6Y3MNFRWW>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/B5DU6GJCB7C6UCQG6YOTN3D4R4YWNAVCNFSM6AAAAACW2LOHSGVHI2DSMVQWIX3LMV43ASLTON2WKOZUGEYTIMRZHAZDSOA>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
|
Still fooking someone is hacking my google account
…On Sun, 22 Mar 2026 at 04:52 Andy Dsouza ***@***.***> wrote:
U guys had full on plan to fooking make me suicide……send the money u
withdrawn from the fooking console…..
On Sun, 22 Mar 2026 at 04:38 u9g ***@***.***> wrote:
> tryHandleCommand in BrowserView's before-input-event handler intercepts
> keyboard events too aggressively, preventing them from reaching web content
> in the built-in browser.
>
> *Arrow keys with modifiers* (Cmd+Arrow, Option+Arrow,
> Option+Shift+Arrow, etc.) are routed to VS Code's command system instead of
> passing through for standard text navigation. On macOS this means
> Cmd+Left/Right (line start/end), Option+Left/Right (word navigation), and
> Option+Shift+Left/Right (word selection) are all broken in web pages loaded
> in the built-in browser.
>
> *Enter* is classified as a "non-editing key", causing it to be
> intercepted rather than delivered to web page input handlers. This breaks
> typing in text inputs, forms, and editors (e.g. Monaco) within the built-in
> browser.
> Fix
>
> - Let all arrow key events pass through to web content
> unconditionally, since they are standard text navigation keys
> - Remove Enter from the isNonEditingKey list so it reaches web content
>
> ------------------------------
> You can view, comment on, or merge this pull request online at:
>
> #303799
> Commit Summary
>
> - dd33c97
> <dd33c97>
> Fix arrow key events not reaching web content in BrowserView
> - ed0608e
> <ed0608e>
> Fix Enter key not reaching web content in BrowserView
>
> File Changes
>
> (1 file <https://github.com/microsoft/vscode/pull/303799/files>)
>
> - *M* src/vs/platform/browserView/electron-main/browserView.ts
> <https://github.com/microsoft/vscode/pull/303799/files#diff-40ec9f5a0ecc43419ebf10b8d9cba3bc1cd982741e40e802ee220d9dc42b83b6>
> (9)
>
> Patch Links:
>
> - https://github.com/microsoft/vscode/pull/303799.patch
> - https://github.com/microsoft/vscode/pull/303799.diff
>
> —
> Reply to this email directly, view it on GitHub
> <#303799?email_source=notifications&email_token=B5DU6GLP23WIMSYJKCSZ2CT4R4YWNA5CNFSNUABEM5UWIORPF5TWS5BNNB2WEL2QOVWGYUTFOF2WK43UF4ZTIMRZHAYTINJXG6THEZLBONXW5KTTOVRHGY3SNFRGKZFFMV3GK3TUVRTG633UMVZF6Y3MNFRWW>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/B5DU6GJCB7C6UCQG6YOTN3D4R4YWNAVCNFSM6AAAAACW2LOHSGVHI2DSMVQWIX3LMV43ASLTON2WKOZUGEYTIMRZHAZDSOA>
> .
> You are receiving this because you are subscribed to this thread.Message
> ID: ***@***.***>
>
|
u9g
added a commit
to u9g/LearnTensors
that referenced
this pull request
Mar 22, 2026
vscode's BrowserView intercepts Enter and Option+Arrow keydown events before they reach web content. Work around this by explicitly binding Enter via addCommand and intercepting corrupted Option+Arrow keydowns on the textarea to fire word-navigation commands on keyup. See microsoft/vscode#303799
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
tryHandleCommandin BrowserView'sbefore-input-eventhandler intercepts keyboard events too aggressively, preventing them from reaching web content in the built-in browser.Arrow keys with modifiers (Cmd+Arrow, Option+Arrow, Option+Shift+Arrow, etc.) are routed to VS Code's command system instead of passing through for standard text navigation. On macOS this means Cmd+Left/Right (line start/end), Option+Left/Right (word navigation), and Option+Shift+Left/Right (word selection) are all broken in web pages loaded in the built-in browser.
Enter is classified as a "non-editing key", causing it to be intercepted rather than delivered to web page input handlers. This breaks typing in text inputs, forms, and editors (e.g. Monaco) within the built-in browser.
Fix
isNonEditingKeylist so it reaches web content