Print a warning if an unmapped button is pressed

This commit is contained in:
Cameron Gutman 2015-06-27 14:47:51 -07:00 committed by Iwan Timmer
parent cd954e4935
commit 5f129e1988

View File

@ -474,8 +474,10 @@ static bool input_handle_event(struct input_event *ev, struct input_device *dev)
dev->leftTrigger = ev->value?UCHAR_MAX:0;
else if (ev->code == dev->map.btn_tr2)
dev->rightTrigger = ev->value?UCHAR_MAX:0;
else
else {
fprintf(stderr, "Unmapped button: %d\n", ev->code);
gamepadModified = false;
}
}
}
break;