summaryrefslogtreecommitdiff
path: root/rotord/src/rotor.h
diff options
context:
space:
mode:
Diffstat (limited to 'rotord/src/rotor.h')
-rw-r--r--rotord/src/rotor.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/rotord/src/rotor.h b/rotord/src/rotor.h
index aa76491..a8e6fca 100644
--- a/rotord/src/rotor.h
+++ b/rotord/src/rotor.h
@@ -249,6 +249,7 @@ namespace Rotor {
parameters[_name]=new Parameter(_type,_desc,_title,_value,_min,_max,_step,_connect);
};
void create_attribute(const string &_attr,const string &_desc,const string &_title,const string &_value,std::vector<std::string> _vals={},std::string _type="string") {
+ if (_vals.size()&&_type!="array") _type="enum"; //hack for incomplete attribute types
attributes[_attr]=new Attribute(_desc,_title,_value,_vals,_type);
};
void create_attribute(string *alias,const string &_attr,const string &_desc,const string &_title,const string &_value,std::vector<std::string> _vals={},std::string _type="string") {