summaryrefslogtreecommitdiffhomepage
path: root/tracker-wii
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2019-06-20 23:05:05 +0200
committerStanislaw Halik <sthalik@misaki.pl>2019-06-20 23:05:05 +0200
commitbf0a67326445428293f96030a2419b55d9d1ffc4 (patch)
tree6a1026137c4d564deb94063506c64eb015e50cef /tracker-wii
parentab87b358c03a80edfcbefcfd2af762ea14275e5a (diff)
tracker/wii: add missing prototype for mingw
Diffstat (limited to 'tracker-wii')
-rw-r--r--tracker-wii/wii_camera.cpp18
1 files changed, 17 insertions, 1 deletions
diff --git a/tracker-wii/wii_camera.cpp b/tracker-wii/wii_camera.cpp
index 1f769819..973d7fab 100644
--- a/tracker-wii/wii_camera.cpp
+++ b/tracker-wii/wii_camera.cpp
@@ -114,6 +114,22 @@ void WIICamera::stop()
Beep(1000, 200);
}
+#ifdef __MINGW32__
+extern "C"
+ DWORD WINAPI BluetoothAuthenticateDevice(
+ HWND hwndParent,
+ HANDLE hRadio,
+ BLUETOOTH_DEVICE_INFO *pbtbi,
+ PWSTR pszPasskey,
+ ULONG ulPasskeyLength
+ );
+
+#ifndef BLUETOOTH_SERVICE_ENABLE
+# define BLUETOOTH_SERVICE_DISABLE 0x00
+# define BLUETOOTH_SERVICE_ENABLE 0x01
+#endif
+
+#endif
wii_camera_status WIICamera::pair()
{
@@ -190,7 +206,7 @@ wii_camera_status WIICamera::pair()
DWORD servicecount = 32;
GUID guids[32];
if (ERROR_SUCCESS != BluetoothEnumerateInstalledServices(hbtlist[i], &btdevinfo, &servicecount, guids)) { error = true; continue; }
- if (ERROR_SUCCESS != BluetoothSetServiceState(hbtlist[i], &btdevinfo, &HumanInterfaceDeviceServiceClass_UUID, BLUETOOTH_SERVICE_ENABLE)) { error = true; continue; }
+ if (ERROR_SUCCESS != BluetoothSetServiceState(hbtlist[i], &btdevinfo, (GUID*)&HumanInterfaceDeviceServiceClass_UUID, BLUETOOTH_SERVICE_ENABLE)) { error = true; continue; }
break;
} while (BluetoothFindNextDevice(hbtdevfd, &btdevinfo));
BluetoothFindDeviceClose(hbtdevfd);