CConfigFile: Implement write_bool_entry

This commit is contained in:
Jookia
2019-07-01 15:54:30 +10:00
committed by Andreas Kling
parent 070a2f8980
commit d2b6f79835

View File

@@ -150,6 +150,10 @@ void CConfigFile::write_num_entry(const String& group, const String& key, int va
{
write_entry(group, key, String::format("%d", value));
}
void CConfigFile::write_bool_entry(const String& group, const String& key, bool value)
{
write_entry(group, key, value ? "1" : "0");
}
void CConfigFile::write_color_entry(const String& group, const String& key, Color value)
{
write_entry(group, key, String::format("%d,%d,%d,%d", value.red(), value.green(), value.blue(), value.alpha()));