There are memory leaks in the latest 3.1.1 Hello World example code:
Code: Select all
bool MyApp::OnInit()
{
MyFrame *frame = new MyFrame();
frame->Show(true);
return true;
}
Code: Select all
bool MyApp::OnInit()
{
MyFrame *frame = new MyFrame();
frame->Show(true);
return true;
}
Thanks for clearing up my confusion.PB wrote:I believe that you are not pedantic, you are just wrong. See e.g. http://docs.wxwidgets.org/trunk/overvie ... etion.html
No I haven't, yet. I'm only beginning with wxWidgets and I didn't expect it to do tricks like this.PB wrote:Or, did you actually try to debug the code, place the breakpoint the frame's dtor and observed it was never called?
I believe that all major C++ GUI toolkits (Qt, MFC, wxWidgets) do it (i.e., manage window pointers) this way...ab396356 wrote:I'm only beginning with wxWidgets and I didn't expect it to do tricks like this.