Hi,
I need to send some arguments in a callback but it doesn't seem to be possible in an object. Basically, I saw that in the callback tutorial:
And I wanted to do that:
But it doesn't seem to be possible, I get the following error:
Thanks.
I need to send some arguments in a callback but it doesn't seem to be possible in an object. Basically, I saw that in the callback tutorial:
Code (cpp) Select
void function(tgui::Gui& gui);
button->bindCallback(std::bind(function, std::ref(gui)), tgui::CheckBox::Checked | tgui::CheckBox::Unchecked);
And I wanted to do that:
Code (cpp) Select
p.button->bindCallback(std::bind(&AddObjectDialog::CloseAndSaveCallback, p.object), this, tgui::Button::LeftMouseClicked);
But it doesn't seem to be possible, I get the following error:
Code (xml) Select
'tgui::CallbackManager::bindCallback' : no overloaded function takes 3 arguments
Thanks.