Fix code and typecasting

This commit is contained in:
Jonathan Campbell
2024-06-06 23:05:07 -07:00
parent 4d8bf31d0e
commit 0d5bde6261

View File

@@ -109,7 +109,7 @@ void ApplyPreventCapMenu(void);
void ApplyPreventCap(void) {
#ifdef WIN32
HANDLE *usr = GetModuleHandle("USER32.DLL");
HMODULE usr = (HMODULE)GetModuleHandle("USER32.DLL");
if (usr) {
BOOL (WINAPI *__SetWindowDisplayAffinity)(HWND hWnd,DWORD dwAffinity) =
(BOOL (WINAPI*)(HWND,DWORD))GetProcAddress(usr,"SetWindowDisplayAffinity");