Make hint keybinding inhibition work
This commit is contained in:
parent
8bce2ba8e8
commit
9f0e1a98a0
@ -60,8 +60,8 @@ class NormalKeyParser(keyparser.CommandKeyParser):
|
|||||||
def __repr__(self):
|
def __repr__(self):
|
||||||
return utils.get_repr(self)
|
return utils.get_repr(self)
|
||||||
|
|
||||||
def _handle_single_key(self, e):
|
def handle(self, e):
|
||||||
"""Override _handle_single_key to abort if the key is a startchar.
|
"""Override to abort if the key is a startchar.
|
||||||
|
|
||||||
Args:
|
Args:
|
||||||
e: the KeyPressEvent from Qt.
|
e: the KeyPressEvent from Qt.
|
||||||
@ -69,13 +69,14 @@ class NormalKeyParser(keyparser.CommandKeyParser):
|
|||||||
Return:
|
Return:
|
||||||
A self.Match member.
|
A self.Match member.
|
||||||
"""
|
"""
|
||||||
# FIXME rewrite this
|
|
||||||
txt = e.text().strip()
|
txt = e.text().strip()
|
||||||
if self._inhibited:
|
if self._inhibited:
|
||||||
self._debug_log("Ignoring key '{}', because the normal mode is "
|
self._debug_log("Ignoring key '{}', because the normal mode is "
|
||||||
"currently inhibited.".format(txt))
|
"currently inhibited.".format(txt))
|
||||||
return QKeySequence.NoMatch
|
return QKeySequence.NoMatch
|
||||||
match = super()._handle_single_key(e)
|
|
||||||
|
match = super().handle(e)
|
||||||
|
|
||||||
if match == QKeySequence.PartialMatch:
|
if match == QKeySequence.PartialMatch:
|
||||||
timeout = config.val.input.partial_timeout
|
timeout = config.val.input.partial_timeout
|
||||||
if timeout != 0:
|
if timeout != 0:
|
||||||
|
Loading…
Reference in New Issue
Block a user