-
Notifications
You must be signed in to change notification settings - Fork 30.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Press BracketLeft to find in explorer and shows Dead #80741
Comments
Cannot reproduce
|
Cannot reproduce either
|
@MarcelloVSilva Do you maybe have a special keyboard layout? |
No, i have a Dell Inspiron 14 5480 and i use his keyboard, i check again and the error stills here. Not just for BracketLeft, but shows the same error when i press
|
Ok, I can reproduce it now on MacOS & Windows with english and german layout, but BracketLeft works. When pressing a modifier key, the key event listener returns 'DEAD', this is normal, but should not be printed to the user. The modifier key is applied. So when I press ' ^ ' then ' a', it shows ' â '. vscode should check the return value of the key event listener and filter out 'DEAD'.
|
Yeah, i use portuguese layout keyboard. With
|
I'm using portuguese layout keyboard as well.
All of these keys prints |
I'm using portuguese layout keyboard as well.
|
@joaomoreno I'd be interested in taking a look at this if that's okay. I've found vscode/src/vs/base/browser/ui/tree/abstractTree.ts Lines 692 to 702 in 385bf0f
The obvious fix here is to amend L699 to include a check for dead keys, however, this seems a bit hacky as private onEventOrInput(e: MouseEvent | StandardKeyboardEvent | string): void {
if (typeof e === 'string') {
this.onInput(e);
} else if (e instanceof MouseEvent || e.keyCode === KeyCode.Escape || (e.keyCode === KeyCode.Backspace && (isMacintosh ? e.altKey : e.ctrlKey))) {
this.onInput('');
} else if (e.keyCode === KeyCode.Backspace) {
this.onInput(this.pattern.length === 0 ? '' : this.pattern.substr(0, this.pattern.length - 1));
} else if (e.browserEvent.key !== 'Dead') {
this.onInput(this.pattern + e.browserEvent.key);
}
} EDIT: vscode/src/vs/base/browser/ui/tree/abstractTree.ts Lines 658 to 665 in 385bf0f
But this still isn't ideal, as it doesn't behave the same as all other inputs. Bit lost here to be honest and would appreciate any pointers. |
@frobinsonj I think the best we can do is exactly what you've done with |
Steps to Reproduce:
Does this issue occur when all extensions are disabled?: Yes
The text was updated successfully, but these errors were encountered: