-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Vim handles keystrokes in wrong sequence if Code is not responding immediately #1340
Comments
Ah, interesting, they get out of sequence. One good way to reproduce this is to write some code that introduces a random delay before handling events. |
Could this piece of code be the cause? https://github.com/VSCodeVim/Vim/blob/master/src/actions/commands/actions.ts#L102 |
Oh shit I think I found the reason why @rebornix @johnfn @xconverge
We have a task queue that is meant to handle the above scenario. However, when we're handling special keys, we just ignore the task queue! |
@Chillee very likely a good catch! |
This is the only thing I dislike about editing in vscode, but it's a huge deal for me. I very frequently run |
action.ts
of this project and you are adding a)
after}
Esc
and then.
quickly.}).
and the state is normal mode.Code takes a few seconds to handle match bracket logic after you press
)
so that's why theEsc
doesn't immediately change the cursor style to Block real quick. However Code is sending the events with correct sequence but we didn't handle them in a good orderThe text was updated successfully, but these errors were encountered: