Qt: Allow binding keyboard keys via fullscreen UI

This commit is contained in:
Connor McLaughlin
2021-03-08 01:39:46 +10:00
parent 39498cda10
commit a0e97059f5
9 changed files with 44 additions and 34 deletions

View File

@ -129,7 +129,10 @@ bool QtDisplayWidget::event(QEvent* event)
{
const QKeyEvent* key_event = static_cast<QKeyEvent*>(event);
if (!key_event->isAutoRepeat())
emit windowKeyEvent(QtUtils::KeyEventToInt(key_event), event->type() == QEvent::KeyPress);
{
emit windowKeyEvent(key_event->key(), static_cast<int>(key_event->modifiers()),
event->type() == QEvent::KeyPress);
}
return true;
}