The view doesn't have any associated frame when using the special "single
view" mode in the sample, so don't try to show it when creating a new view.
This resulted in a crash when starting the sample with --single command line
parameter.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68024
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
wxFrame* frame = app.CreateChildFrame(this, true);
wxASSERT(frame == GetFrame());
m_canvas = new MyCanvas(this);
+ frame->Show();
}
else // single document mode
{
doc->GetCommandProcessor()->SetEditMenu(app.GetMainWindowEditMenu());
doc->GetCommandProcessor()->Initialize();
}
- GetFrame()->Show();
return true;
}