Mercurial > minori
view src/core/ini.cc @ 301:b1f625b0227c
*: convert all files CRLF -> LF
some files were in DOS format, others were in unix. now everything
(that at least is under our control) should all be the same format
author | Paper <paper@paper.us.eu.org> |
---|---|
date | Mon, 13 May 2024 15:04:51 -0400 |
parents | ec0a2b5493f8 |
children |
line wrap: on
line source
#include "core/ini.h" namespace INI { std::string GetIniString(const mINI::INIStructure& ini, const std::string& section, const std::string& key, const std::string& def) { if (!ini.has(section) || !ini.get(section).has(key)) return def; return ini.get(section).get(key); } bool GetIniBool(const mINI::INIStructure& ini, const std::string& section, const std::string& key, bool def) { return Strings::ToBool(GetIniString(ini, section, key, ""), def); } }