I am trying to programmatically change the value of wxRadioButton as the user does. Changing the value does not cause an event corresponding to the button, and this makes sense, since the documentation clearly states:
wxRadioButton::SetValue void SetValue(const bool value) Sets the radio button to selected or deselected status. This does not cause a wxEVT_COMMAND_RADIOBUTTON_SELECTED event to get emitted.
So the question is, how can I trigger a programmatically generated event for wxRadioButton?
I assume this has something to do with:
wxWindow window->AddPendingEvent(wxEvent *event )
Nice to appreciate a simple example.
source share