mirror of
https://github.com/spice2x/spice2x.github.io.git
synced 2026-11-29 10:48:56 -08:00
fix sdvx windowed mode mouse emulation double register
This commit is contained in:
1 parent
c83496776e
commit
63bfef7c69
1 file changed
+8
@@ -7,6 +7,7 @@
|
||||
#include "settings.h"
|
||||
#include "transform.h"
|
||||
|
||||
#include "hooks/graphics/graphics.h"
|
||||
#include "touch/touch.h"
|
||||
#include "util/logging.h"
|
||||
|
||||
@@ -141,6 +142,13 @@ namespace nativetouch::inject {
|
||||
end_mouse_contact(window);
|
||||
}
|
||||
|
||||
// SDVX accepts both mouse and touch on its windowed subscreen, causing duplicate input.
|
||||
if (GRAPHICS_WINDOWED &&
|
||||
window == SDVX_SUBSCREEN_WINDOW &&
|
||||
message >= WM_MOUSEFIRST && message <= WM_MOUSELAST) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user