MCPcopy Create free account
hub / github.com/PolyMC/PolyMC / IsWindows11

Function IsWindows11

launcher/ui/WinDarkmode.cpp:38–42  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

36}
37
38BOOL IsWindows11()
39{
40 HMODULE hKern32 = GetModuleHandleW(L"kernel32.dll");
41 return GetProcAddress(hKern32, "Wow64SetThreadDefaultGuestMachine") != NULL; // Win11 21h2+
42}
43
44BOOL IsWindows10_Only()
45{

Callers 1

setWindowDarkModeEnabledFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected