Skip to content

Instantly share code, notes, and snippets.

View bperrenoud's full-sized avatar

Basile Perrenoud bperrenoud

View GitHub Profile
@bperrenoud
bperrenoud / Win7TouchInput
Created April 1, 2014 08:16
Update for unity's touchscript library. Disable windows 7 long touch event and visual feedback. Allow to catch press events immediately. Update the Win7TouchInput file with this code
// Current Init Method with one call added
private void init()
{
if (Application.platform != RuntimePlatform.WindowsPlayer) return;
touchInputSize = Marshal.SizeOf(typeof(TOUCHINPUT));
hMainWindow = GetForegroundWindow();
RegisterTouchWindow(hMainWindow, 0);