Slider code generation generates compilation-error code for interaction (virtual functions)
When requiring a virtual function for a slider on value change / start / confirmed (touchgfx 4.10),
the code generated is broken.
The callback that calls the cvirtual function contains a comparison between a touchgfx::Slider* and a int*
if (&src == &value) {
virtual_function();
}
if changed with something with a little more sense, like:
if (src.getValue() == value) {
vierual_function()
}
the error is a discarded qualifiers. This error is raised because the Slider getValue method is not declared as const and the callback gets as input a const touchgfx::Slider. So the method should be:
int getValue() const {
return current_value;
}
Am I right?
