mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-01 14:58:14 +00:00
Better (but not great) workaround for key bindings that pop up dialogs.
This commit is contained in:
1 parent
eee4640962
commit
c037f6731d
5 files changed
+32
-5
No files matched your search
@@ -153,6 +153,23 @@ void ControlMapper::UpdateAnalogOutput(int stick) {
|
||||
setPSPAnalog_(stick, x, y);
|
||||
}
|
||||
|
||||
void ControlMapper::ForceReleaseVKey(int vkey) {
|
||||
std::vector<KeyMap::MultiInputMapping> multiMappings;
|
||||
if (KeyMap::InputMappingsFromPspButton(vkey, &multiMappings, true)) {
|
||||
for (const auto &entry : multiMappings) {
|
||||
for (const auto &mapping : entry.mappings) {
|
||||
int direction = 0;
|
||||
if (mapping.IsAxis() && IsSignedAxis(mapping.Axis(&direction))) {
|
||||
curInput_[mapping] = direction == -1 ? -1 : 1;
|
||||
} else {
|
||||
curInput_[mapping] = 0.0f;
|
||||
}
|
||||
UpdatePSPState(mapping);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static int RotatePSPKeyCode(int x) {
|
||||
switch (x) {
|
||||
case CTRL_UP: return CTRL_RIGHT;
|
||||
|
||||
Reference in new issue
Block a user