Conversation
| self.insert_keybindings | ||
| .find_binding(modifier, KeyCode::Char(c)) | ||
| .unwrap_or_else(|| { | ||
| if modifier == KeyModifiers::NONE |
There was a problem hiding this comment.
I don't understand this part, with or without your changes. Do you have any clue?
There was a problem hiding this comment.
As far as I can tell, it seems to be handling inputs with key modifiers. His change checks for alt at the beginning and handles it like vim does there, then does the other checks reedline does already.
There was a problem hiding this comment.
It seems to just be checking if it can enter that key as a regular input (not handling cases where just the control modifier is held) and also making the key uppercase if shift is held.
My function does "consume" alt inputs (by flipping the alt bit) so checking if alt is pressed in that list is a bit redundant hence the comment.
There was a problem hiding this comment.
I mean what's so special about ctrl + alt and ctrl + alt + shift? Why not just check whether shift is pressed? The comments before make me even more confused...
There was a problem hiding this comment.
honestly not entirely sure but I've decided to keep the original logic in-case it's just something I don't understand
My implementation is a little crude, I'm open to any feedback to make changes to it before opening the PR.
fixes #983