summaryrefslogtreecommitdiff
path: root/qutebrowser/keyinput/basekeyparser.py
diff options
context:
space:
mode:
authorFlorian Bruhin <git@the-compiler.org>2018-03-01 20:45:55 +0100
committerFlorian Bruhin <git@the-compiler.org>2018-03-04 20:21:57 +0100
commit7cb781cc92a4d541659e243d3d92be6934e2b26c (patch)
tree2d99adf61053904fcd472cd86e48130dfbc10449 /qutebrowser/keyinput/basekeyparser.py
parent693178c8ee0c22f5b0c168a1dcbca9db1e5dd49c (diff)
downloadqutebrowser-7cb781cc92a4d541659e243d3d92be6934e2b26c.tar.gz
qutebrowser-7cb781cc92a4d541659e243d3d92be6934e2b26c.zip
Simplify handling of modifier-only keys
Now that we don't rely on str(KeyInfo) being empty anywhere, there's no reason to return an empty string for only-modifier keypresses anymore. While those keys can't be bound (QKeySequence('Shift') == Qt.Key_unknown) there's also no reason to explicitly ignore them.
Diffstat (limited to 'qutebrowser/keyinput/basekeyparser.py')
-rw-r--r--qutebrowser/keyinput/basekeyparser.py4
1 files changed, 0 insertions, 4 deletions
diff --git a/qutebrowser/keyinput/basekeyparser.py b/qutebrowser/keyinput/basekeyparser.py
index 2c934617b..a8501ab4c 100644
--- a/qutebrowser/keyinput/basekeyparser.py
+++ b/qutebrowser/keyinput/basekeyparser.py
@@ -128,10 +128,6 @@ class BaseKeyParser(QObject):
txt = str(keyutils.KeyInfo.from_event(e))
self._debug_log("Got key: 0x{:x} / text: '{}'".format(key, txt))
- if keyutils.is_modifier_key(key):
- self._debug_log("Ignoring, only modifier")
- return QKeySequence.NoMatch
-
if (txt.isdigit() and self._supports_count and not
(not self._count and txt == '0')):
assert len(txt) == 1, txt