Don't crash if there's no top window.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63355 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -235,6 +235,8 @@ wxChoice::GetClassDefaultAttributes(wxWindowVariant WXUNUSED(variant))
|
||||
|
||||
// FIXME: Use better dummy window?
|
||||
wxWindow* wnd = wxTheApp->GetTopWindow();
|
||||
if (!wnd)
|
||||
return attrs;
|
||||
|
||||
attrs.font = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
|
||||
|
||||
|
Reference in New Issue
Block a user