MCPcopy Create free account
hub / github.com/OpenRCT2/OpenRCT2 / WIN32_GetModuleFileNameW

Function WIN32_GetModuleFileNameW

src/openrct2/platform/Platform.Win32.cpp:311–325  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

309 }
310
311 static std::wstring WIN32_GetModuleFileNameW(HMODULE hModule)
312 {
313 uint32_t wExePathCapacity = 128;
314 std::wstring exePath;
315
316 uint32_t size;
317 do
318 {
319 wExePathCapacity *= 2;
320 exePath.resize(wExePathCapacity);
321 size = GetModuleFileNameW(hModule, exePath.data(), wExePathCapacity);
322 } while (size >= wExePathCapacity);
323 exePath.resize(size);
324 return exePath;
325 }
326
327 static u8string WIN32_GetModuleFileNameUTF8(HMODULE hModule)
328 {

Callers 3

SetUpFileAssociationFunction · 0.85
SetupUriProtocolFunction · 0.85

Calls 1

dataMethod · 0.45

Tested by

no test coverage detected