mirror of
https://github.com/libretro/ppsspp.git
synced 2024-12-04 15:06:25 +00:00
d5c2560212
Save the bindings in the conf file in a map.
22 lines
357 B
C++
22 lines
357 B
C++
#include "qkeyedit.h"
|
|
#include <QKeySequence>
|
|
#include <QKeyEvent>
|
|
|
|
QKeyEdit::QKeyEdit(QWidget *parent) :
|
|
QLineEdit(parent)
|
|
{
|
|
}
|
|
|
|
bool QKeyEdit::event(QEvent *e)
|
|
{
|
|
if(e->type() == QEvent::KeyPress)
|
|
{
|
|
QKeyEvent *ke = static_cast<QKeyEvent *>(e);
|
|
QKeySequence seq(ke->key());
|
|
setText(seq.toString());
|
|
return true;
|
|
}
|
|
|
|
return QLineEdit::event(e);
|
|
}
|