mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Also call SendMouseDeltaAxis directly from NativeMouseDelta for lower latency.
This commit is contained in:
parent
d397635e49
commit
ce6b05174a
1 changed files with 11 additions and 9 deletions
|
@ -1324,15 +1324,7 @@ void NativeAxis(const AxisInput *axes, size_t count) {
|
|||
}
|
||||
}
|
||||
|
||||
void NativeMouseDelta(float dx, float dy) {
|
||||
// Remap, shared code. Then send it as a regular axis event.
|
||||
if (!g_Config.bMouseControl)
|
||||
return;
|
||||
|
||||
MouseEventProcessor::ProcessDelta(time_now_d(), dx, dy);
|
||||
}
|
||||
|
||||
// Called from NativeFrame.
|
||||
// Called from NativeFrame and from NativeMouseDelta.
|
||||
static void SendMouseDeltaAxis() {
|
||||
float mx, my;
|
||||
MouseEventProcessor::MouseDeltaToAxes(time_now_d(), &mx, &my);
|
||||
|
@ -1356,6 +1348,16 @@ static void SendMouseDeltaAxis() {
|
|||
}
|
||||
}
|
||||
|
||||
void NativeMouseDelta(float dx, float dy) {
|
||||
// Remap, shared code. Then send it as a regular axis event.
|
||||
if (!g_Config.bMouseControl)
|
||||
return;
|
||||
|
||||
MouseEventProcessor::ProcessDelta(time_now_d(), dx, dy);
|
||||
|
||||
SendMouseDeltaAxis();
|
||||
}
|
||||
|
||||
void NativeAccelerometer(float tiltX, float tiltY, float tiltZ) {
|
||||
if (g_Config.iTiltInputType == TILT_NULL) {
|
||||
// if tilt events are disabled, don't do anything special.
|
||||
|
|
Loading…
Add table
Reference in a new issue