Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

libtorc-baseui: Tweak custom keypress handling

  • Loading branch information...
commit fe9703de58529fd895f66bd6e38d821e6cebe923 1 parent 83692dc
Mark Kendall mark-kendall authored
3  libs/libtorc-baseui/opengl/uiopenglwindow.cpp
@@ -270,9 +270,10 @@ void UIOpenGLWindow::customEvent(QEvent *Event)
270 270 close();
271 271 break;
272 272 case Torc::KeyPress:
  273 + case Torc::KeyRelease:
273 274 {
274 275 QKeyEvent *keyevent = new QKeyEvent(
275   - QEvent::KeyPress,
  276 + event == Torc::KeyPress ? QEvent::KeyPress : QEvent::KeyRelease,
276 277 torcevent->Data().value("key").toInt(),
277 278 TORC_KEYEVENT_MODIFIERS,
278 279 torcevent->Data().value("source").toString());
3  libs/libtorc-baseui/uiactions.cpp
@@ -74,7 +74,8 @@ int UIActions::GetActionFromKey(QEvent *Event)
74 74
75 75 // pressed and released
76 76 if (key == Qt::Key_Return ||
77   - key == Qt::Key_Enter)
  77 + key == Qt::Key_Enter ||
  78 + key == Qt::Key_Select)
78 79 {
79 80 LOG(VB_GENERAL, LOG_DEBUG, QString("KeyPress/Release %1").arg(key, 0, 16));
80 81 return keyevent->type() == QEvent::KeyPress ? Torc::Pushed : Torc::Released;

0 comments on commit fe9703d

Please sign in to comment.
Something went wrong with that request. Please try again.