mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Prevent the accelerometer from being mapped to controls directly until we can create sane UI for that.
This commit is contained in:
parent
ad951bc0d4
commit
5f2954bc69
1 changed files with 10 additions and 0 deletions
|
@ -264,6 +264,16 @@ void KeyMappingNewKeyDialog::key(const KeyInput &key) {
|
|||
}
|
||||
|
||||
void KeyMappingNewKeyDialog::axis(const AxisInput &axis) {
|
||||
// Ignore the accelerometer for mapping for now.
|
||||
switch (axis.axisId) {
|
||||
case JOYSTICK_AXIS_ACCELEROMETER_X:
|
||||
case JOYSTICK_AXIS_ACCELEROMETER_Y:
|
||||
case JOYSTICK_AXIS_ACCELEROMETER_Z:
|
||||
return;
|
||||
default:
|
||||
;
|
||||
}
|
||||
|
||||
if (axis.value > AXIS_BIND_THRESHOLD) {
|
||||
KeyDef kdf(axis.deviceId, KeyMap::TranslateKeyCodeFromAxis(axis.axisId, 1));
|
||||
screenManager()->finishDialog(this, DR_OK);
|
||||
|
|
Loading…
Add table
Reference in a new issue