Address assorted feedback

This commit is contained in:
Henrik Rydgård 2023-04-01 09:01:27 +02:00
parent 04321284c0
commit 0b574613b9
3 changed files with 6 additions and 8 deletions

View file

@ -125,7 +125,7 @@ void ControlMapper::SetPSPAxis(int device, int stick, char axis, float value) {
bool ignore = false;
if (inDeadZone && lastNonDeadzoneDeviceID_[stick] != device) {
// Ignore this event! See issue #15465
ignore = true;
ignore = true;
}
if (!inDeadZone) {
@ -325,10 +325,10 @@ bool ControlMapper::Key(const KeyInput &key, bool *pauseTrigger) {
}
// TODO: See if this can be simplified further somehow.
bool mappingFound = KeyMap::InputMappingToPspButton(mapping, nullptr);
DEBUG_LOG(SYSTEM, "Key: %d DeviceId: %d", key.keyCode, key.deviceId);
if (!mappingFound || key.deviceId == DEVICE_ID_DEFAULT) {
if ((key.flags & KEY_DOWN) && key.keyCode == NKCODE_BACK) {
if ((key.flags & KEY_DOWN) && key.keyCode == NKCODE_BACK) {
bool mappingFound = KeyMap::InputMappingToPspButton(mapping, nullptr);
DEBUG_LOG(SYSTEM, "Key: %d DeviceId: %d", key.keyCode, key.deviceId);
if (!mappingFound || key.deviceId == DEVICE_ID_DEFAULT) {
*pauseTrigger = true;
return true;
}

View file

@ -187,7 +187,6 @@ void WebSocketInputState::ButtonsPress(DebuggerRequest &req) {
}
press.button = info->second;
// TODO: Route into the control mapper's PSPKey function instead.
__CtrlUpdateButtons(press.button, 0);
pressTickets_.push_back(press);
}
@ -201,7 +200,6 @@ void WebSocketInputState::Broadcast(net::WebSocketServer *ws) {
for (PressInfo &press : pressTickets_) {
press.duration--;
if (press.duration == -1) {
// TODO: Route into the control mapper's PSPKey function instead.
__CtrlUpdateButtons(0, press.button);
ws->Send(press.Event());
}

View file

@ -1319,6 +1319,7 @@ Invalid / Unknown (%d)
static void DrawAudioDebugStats(UIContext *ctx, const Bounds &bounds) {
FontID ubuntu24("UBUNTU24");
char statbuf[4096] = { 0 };
System_AudioGetDebugStats(statbuf, sizeof(statbuf));
@ -1337,7 +1338,6 @@ static void DrawControlDebug(UIContext *ctx, const ControlMapper &mapper, const
char statbuf[4096] = { 0 };
mapper.GetDebugString(statbuf, sizeof(statbuf));
// System_AudioGetDebugStats(statbuf, sizeof(statbuf));
ctx->Flush();
ctx->BindFontTexture();