Closed guardianblue closed 4 months ago
Would be great if we can reuse this for voltex subscreen as well.
By the way, I noticed that mouse clicks stop working after signing in with windowed subscreen, which is a problem. The PIN pad always works reliably, but when you try to click on other menu items, it works about 10% of the time. You still get the touch indicators (circle splash effect) but the menu items can't actually be clicked.
Not entirely sure why this happens, but when I try to adjust the EQ sliders, I see phantom touches... I also noticed that clicking on the primary window also registers touches. I'm thinking that maybe multiple touches are being detected by the game, causing some UI elements to not detect them.
edit: enabling overlay in the main window (press f12 for example) "fixes" this problem so it's definitely mouse clicks being passed to the game and interfering with touch emulation...
Looks like when using Windowed subscreen both the touch and mouse code paths of wintouchemu are invoked, and might have caused some race condition.
I will fix that as well.
Yeah, in wintouchemu.cpp, in the if statement starting at line 144
if (touch_event) {
...
} else if (USE_MOUSE && !mouse_used) {
..
} else {
...
}
I see all three paths being exercised. If I force it so that the elseif and else part never runs, the problem goes away.
The patch should have fixed it.
Thanks for a quick turnaround. Only thing I noticed so far is that I was able to close the sub window in SDVX. Nothing logged in the log, it just closes when I press X
Yeah sorry, the patch was wrong (silly me did git commit amend without adding). Updated the patch and it should work.
Related note, the touch emu hooking seems to be a bit chaotic at the moment, I will try to refactor that a bit later.
I'm still having issues clicking around in TDJ subscreen. Trying to click on menus work maybe half the time.
I think your previous change was working better - did you mean to drop the changes in wintouchemu.cpp around line 245?
I was dropping the change in line 245 because it wasn't making a difference on my side
Might as well just put it back.
Sure - I can just put it back and integrate it momentarily. I'd like to release a new version to address the touch issue.
Done. Thanks for the contributions!
Tested with:
wsub-fix2.patch