diff options
author | hut <hut@lavabit.com> | 2010-04-16 16:27:56 +0200 |
---|---|---|
committer | hut <hut@lavabit.com> | 2010-04-16 16:27:56 +0200 |
commit | e0992c0b9bd3159c6097b1f9fbc407393aee1a54 (patch) | |
tree | 3434f522c566b622ccb30e1c6421b7ef159c023e | |
parent | 48ff03e6391057c17d7c0478c64f6ce8ae2f9d2a (diff) | |
download | ranger-e0992c0b9bd3159c6097b1f9fbc407393aee1a54.tar.gz |
keymap: make lines shorter
-rw-r--r-- | ranger/container/keymap.py | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/ranger/container/keymap.py b/ranger/container/keymap.py index e09c9610..60272be0 100644 --- a/ranger/container/keymap.py +++ b/ranger/container/keymap.py @@ -24,23 +24,22 @@ from ranger.ext.keybinding_parser import parse_keybinding, \ MAX_ALIAS_RECURSION = 20 FUNC = 'func' -DIRECTION = 'direction' DIRARG = 'dir' ALIASARG = 'alias' class CommandArgs(object): """The arguments which are passed to a keybinding function""" - def __init__(self, fm, widget, keybuffer): + def __init__(self, fm, widget, keybuf): self.fm = fm self.wdg = widget - self.keybuffer = keybuffer - self.n = keybuffer.quant - self.direction = keybuffer.directions and keybuffer.directions[0] or None - self.directions = keybuffer.directions - self.keys = str(keybuffer) - self.matches = keybuffer.matches - self.match = keybuffer.matches and keybuffer.matches[0] or None - self.binding = keybuffer.command + self.keybuffer = keybuf + self.n = keybuf.quant + self.direction = keybuf.directions and keybuf.directions[0] or None + self.directions = keybuf.directions + self.keys = str(keybuf) + self.matches = keybuf.matches + self.match = keybuf.matches and keybuf.matches[0] or None + self.binding = keybuf.command @staticmethod def from_widget(widget): @@ -276,7 +275,8 @@ class KeyBuffer(object): self.tree_pointer = self.tree_pointer._tree if isinstance(self.tree_pointer, Binding): if self.tree_pointer.alias: - self.key_queue.extend(parse_keybinding(self.tree_pointer.alias)) + keys = parse_keybinding(self.tree_pointer.alias) + self.key_queue.extend(keys) self.tree_pointer = self.keymap._tree self.max_alias_recursion -= 1 else: |