Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
lambdalisue committed Jul 20, 2016
1 parent e609743 commit ee5a56e
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions src/gui/input.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -151,16 +151,12 @@ QString InputConv::convertMouse(Qt::MouseButton bt, QEvent::Type type, Qt::Keybo
QString InputConv::convertKey(const QString& text, int k, Qt::KeyboardModifiers mod)
{
if (specialKeys.contains(k)) {
return QString("<%1%2>").arg(modPrefix(mod)).arg(specialKeys.value(k));
return QString("<%1>").arg(specialKeys.value(k));
}

QChar c;
// Escape < and backslash
if (text == "<") {
return QString("<%1%2>").arg(modPrefix(mod)).arg("lt");
} else if (text == "\\") {
return QString("<%1%2>").arg(modPrefix(mod)).arg("Bslash");
} else if (text.isEmpty()) {
if (text.isEmpty()) {
// on macs, text is empty for ctrl+key and cmd+key combos (with or without alt)
if (mod & ControlModifier || mod & CmdModifier) {
// ignore ctrl, alt and cmd key combos by themselves
Expand Down

0 comments on commit ee5a56e

Please sign in to comment.