Add char to config

This commit is contained in:
scorpion-26 2023-07-19 00:59:54 +02:00
parent 18f3e123ed
commit 49a73063d5

View file

@ -43,6 +43,17 @@ void ApplyProperty<double>(double& propertyToSet, const std::string_view& value)
propertyToSet = std::stod(valStr.c_str()); propertyToSet = std::stod(valStr.c_str());
} }
template<>
void ApplyProperty<char>(char& propertyToSet, const std::string_view& value)
{
if (value.size() > 1)
{
LOG("Invalid size for char property: " << value);
return;
}
propertyToSet = value[0];
}
template<> template<>
void ApplyProperty<bool>(bool& propertyToSet, const std::string_view& value) void ApplyProperty<bool>(bool& propertyToSet, const std::string_view& value)
{ {