Make ManyMouse work on Windows, even when compiled with Unicode support.
authorRyan C. Gordon <icculus@icculus.org>
Wed, 16 Nov 2011 03:50:59 -0500
changeset 116 b10b5fb6d8e0
parent 115 00ccb93a8e38
child 117 a4676b3200fd
Make ManyMouse work on Windows, even when compiled with Unicode support.

Thanks to Stian Fauskanger for the fix!
windows_wminput.c
--- a/windows_wminput.c	Sat Oct 15 13:44:16 2011 -0400
+++ b/windows_wminput.c	Wed Nov 16 03:50:59 2011 -0500
@@ -112,7 +112,7 @@
         return 1;
 
     #define LOOKUP(x) { if (!symlookup(dll, (void **) &p##x, #x)) return 0; }
-    dll = LoadLibrary("user32.dll");
+    dll = LoadLibrary(TEXT("user32.dll"));
     if (dll == NULL)
         return 0;
 
@@ -131,7 +131,7 @@
     LOOKUP(DispatchMessageA);
     LOOKUP(DestroyWindow);
 
-    dll = LoadLibrary("kernel32.dll");
+    dll = LoadLibrary(TEXT("kernel32.dll"));
     if (dll == NULL)
         return 0;
 
@@ -142,7 +142,7 @@
     LOOKUP(LeaveCriticalSection);
     LOOKUP(DeleteCriticalSection);
 
-    dll = LoadLibrary("setupapi.dll");
+    dll = LoadLibrary(TEXT("setupapi.dll"));
     if (dll == NULL)
         return 0;