MCPcopy Create free account
hub / github.com/BeneficialCode/WinArk / ReadBool

Method ReadBool

WinArk/IniFile.cpp:18–23  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

16}
17
18bool IniFile::ReadBool(PCWSTR section, PCWSTR name, bool defaultValue) {
19 auto value = ReadInt(section, name, -1);
20 if (value == -1)
21 return defaultValue;
22 return value ? true : false;
23}
24
25int IniFile::ReadInt(PCWSTR section, PCWSTR name, int defaultValue) {
26 return ::GetPrivateProfileInt(section, name, defaultValue, _path);

Callers 1

LoadMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected