spice2x / spice2x.github.io

🌶️ spice2x is a spicier fork of SpiceTools with hundreds of bug fixes and new features 🌶️
https://spice2x.github.io/
GNU General Public License v3.0
87 stars 2 forks source link

launcher.cpp calls is_touch_available() too early #120

Open sp2xdev opened 4 months ago

sp2xdev commented 4 months ago

Game and version

Nostalgia, Winning Eleven, Shogikai

Version of spice2x

all, including mainline spicetools

Attached log.txt file, if available

n/a

Describe the issue

For the games mentioned above, launcher.cpp calls is_touch_available. This routine has a side effect of initializing touch subsystem, but since RI manager is not initialized yet, it always falls back to Win8/Win7 touch API instead of preferring RIM touch code, which is less ideal.

All of this is only done to automatically show a cursor when a touch screen is not detected. This code need to be refactored so that it's called after RI manager is initialized, but before each game's attach() is returned