Add checks for supported variant types
Add checks for supported variant types in 'build_control_ui'.
This commit is contained in:
parent
1fbc9aaa69
commit
00ed7c81d3
@ -702,6 +702,13 @@ GenericPluginUI::build_control_ui (const Evoral::Parameter& param,
|
|||||||
return control_ui;
|
return control_ui;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (desc.datatype != Variant::INT && desc.datatype != Variant::LONG &&
|
||||||
|
desc.datatype != Variant::FLOAT && desc.datatype != Variant::DOUBLE &&
|
||||||
|
desc.datatype != Variant::BOOL) {
|
||||||
|
/* unsupported variant type */
|
||||||
|
return control_ui;
|
||||||
|
}
|
||||||
|
|
||||||
assert(mcontrol);
|
assert(mcontrol);
|
||||||
|
|
||||||
/* See if there any named values for our input value */
|
/* See if there any named values for our input value */
|
||||||
@ -864,6 +871,13 @@ GenericPluginUI::build_control_ui (const Evoral::Parameter& param,
|
|||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
|
if (desc.datatype != Variant::INT && desc.datatype != Variant::LONG &&
|
||||||
|
desc.datatype != Variant::FLOAT && desc.datatype != Variant::DOUBLE &&
|
||||||
|
desc.datatype != Variant::BOOL) {
|
||||||
|
/* unsupported variant type */
|
||||||
|
return control_ui;
|
||||||
|
}
|
||||||
|
|
||||||
control_ui->display = manage (new EventBox);
|
control_ui->display = manage (new EventBox);
|
||||||
control_ui->display->set_name ("ParameterValueDisplay");
|
control_ui->display->set_name ("ParameterValueDisplay");
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user