Skip to content

Commit

Permalink
Address assorted feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
hrydgard committed Apr 1, 2023
1 parent 0432128 commit 0b57461
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 8 deletions.
10 changes: 5 additions & 5 deletions Core/ControlMapper.cpp
Expand Up @@ -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) {
Expand Down Expand Up @@ -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;
}
Expand Down
2 changes: 0 additions & 2 deletions Core/Debugger/WebSocket/InputSubscriber.cpp
Expand Up @@ -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);
}
Expand All @@ -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());
}
Expand Down
2 changes: 1 addition & 1 deletion UI/EmuScreen.cpp
Expand Up @@ -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));

Expand All @@ -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();
Expand Down

0 comments on commit 0b57461

Please sign in to comment.