Commit cfa2fc36 authored by Don Gagne's avatar Don Gagne

Allow additions to enum lists

parent 7a791d77
......@@ -260,3 +260,9 @@ void FactMetaData::setTranslators(Translator rawTranslator, Translator cookedTra
_rawTranslator = rawTranslator;
_cookedTranslator = cookedTranslator;
}
void FactMetaData::addEnumInfo(const QString& name, const QVariant& value)
{
_enumStrings << name;
_enumValues << value;
}
......@@ -79,6 +79,9 @@ public:
Translator rawTranslator (void) const { return _rawTranslator; }
Translator cookedTranslator (void) const { return _cookedTranslator; }
/// Used to add new values to the enum lists after the meta data has been loaded
void addEnumInfo(const QString& name, const QVariant& value);
void setDecimalPlaces (int decimalPlaces) { _decimalPlaces = decimalPlaces; }
void setDefaultValue (const QVariant& defaultValue);
void setEnumInfo (const QStringList& strings, const QVariantList& values);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment