I my wx application, I have a join able thread. From wxThread::Entry() function, I am posting an event as follows,
Code: Select all
wxThreadEvent* evt = new wxThreadEvent(); evt->SetId(kMerge); wxQueueEvent(wxTheApp, evt);
If I use wxEXEC_SYNC then all goes okay. wxApp::OnExit() is not triggered when ffmpeg gets closed.
wxExecute won't work in Thread, that is why I am posting event so it can be called from main thread.
How I can prevent wxApp::OnExit() if I am using wxEXEC_ASYNC flag. Please suggest.