Fix moving with arrow keys in prompt (#1070)

pull/1071/head
ath3 3 years ago committed by GitHub
parent e0540fbcc4
commit c7cb7527be
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -430,8 +430,8 @@ impl Component for Prompt {
} }
alt!('b') | alt!(Left) => self.move_cursor(Movement::BackwardWord(1)), alt!('b') | alt!(Left) => self.move_cursor(Movement::BackwardWord(1)),
alt!('f') | alt!(Right) => self.move_cursor(Movement::ForwardWord(1)), alt!('f') | alt!(Right) => self.move_cursor(Movement::ForwardWord(1)),
ctrl!('b') | ctrl!(Left) => self.move_cursor(Movement::BackwardChar(1)), ctrl!('b') | key!(Left) => self.move_cursor(Movement::BackwardChar(1)),
ctrl!('f') | ctrl!(Right) => self.move_cursor(Movement::ForwardChar(1)), ctrl!('f') | key!(Right) => self.move_cursor(Movement::ForwardChar(1)),
ctrl!('e') | key!(End) => self.move_end(), ctrl!('e') | key!(End) => self.move_end(),
ctrl!('a') | key!(Home) => self.move_start(), ctrl!('a') | key!(Home) => self.move_start(),
ctrl!('w') => self.delete_word_backwards(), ctrl!('w') => self.delete_word_backwards(),

Loading…
Cancel
Save