summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrabite <rabite@posteo.de>2020-02-12 13:41:35 +0100
committerrabite <rabite@posteo.de>2020-02-12 13:41:35 +0100
commit0de02b36d4f5363e5da7fc81b5e64841408fcf03 (patch)
treed326e9af986af2aae0f1c9091806d1b6f55b5e99
parent800401825c3b51ec0a36ad22c7fb7e4d7e0eda8a (diff)
print more diagnostics and possible fixjumpdebug
-rw-r--r--src/keybind.rs14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/keybind.rs b/src/keybind.rs
index 7e7b000..4bdbe52 100644
--- a/src/keybind.rs
+++ b/src/keybind.rs
@@ -53,8 +53,11 @@ where
}
fn do_key(&mut self, key: Key) -> HResult<()> {
- dbg!(&key);
+ dbg!("\n");
+ dbg!("Looking in map: ", self.search_in());
+ dbg!("for key: ", &key);
let gkey = AnyKey::from(key);
+ dbg!("as anykey: ", &gkey);
// Moving takes priority
if let Some(movement) = self.get_core()?
@@ -62,7 +65,7 @@ where
.keybinds
.movement
.get(gkey) {
- dbg!(movement);
+ dbg!("found bind: ", movement);
match self.movement(movement) {
Ok(()) => return Ok(()),
Err(HError::KeyBind(KeyBindError::MovementUndefined)) => {}
@@ -75,10 +78,13 @@ where
let bindings = self.search_in();
if let Some(action) = bindings.get(key) {
- return self.do_action(dbg!(action))
+ dbg!("found bind: ", action);
+ return self.do_action(action)
} else if let Some(any_key) = gkey.any() {
if let Some(action) = bindings.get(any_key) {
+ dbg!("found bind: ", action);
let action = action.insert_key_param(key);
+ dbg!("turned into: ", action);
return self.do_action(dbg!(&action));
}
}
@@ -673,7 +679,7 @@ impl Default for Bindings<FileBrowserAction> {
let key = match action {
LeftColumnDown => Char(']'),
LeftColumnUp => Char('['),
- GotoHome => Char('~'),
+ GotoHome => Char('9'),
TurboCd => Char('/'),
SelectExternal => Alt(' '),
EnterDirExternal => Char('/'),