Unnamed repository; edit this file 'description' to name the repository.
Make key macro more portable
Nehliin 2021-10-28
parent a4c5f46 · commit da4d934
-rw-r--r--helix-term/src/keymap.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/helix-term/src/keymap.rs b/helix-term/src/keymap.rs
index 8f59060f..ed7f7edd 100644
--- a/helix-term/src/keymap.rs
+++ b/helix-term/src/keymap.rs
@@ -12,13 +12,13 @@ use std::{
#[macro_export]
macro_rules! key {
($key:ident) => {
- KeyEvent {
+ ::helix_view::input::KeyEvent {
code: ::helix_view::keyboard::KeyCode::$key,
modifiers: ::helix_view::keyboard::KeyModifiers::NONE,
}
};
($($ch:tt)*) => {
- KeyEvent {
+ ::helix_view::input::KeyEvent {
code: ::helix_view::keyboard::KeyCode::Char($($ch)*),
modifiers: ::helix_view::keyboard::KeyModifiers::NONE,
}