DoGetBestSize may be called before m_text and m_choice are set,
so check git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27896 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -205,6 +205,8 @@ wxComboBox::~wxComboBox()
|
|||||||
|
|
||||||
wxSize wxComboBox::DoGetBestSize() const
|
wxSize wxComboBox::DoGetBestSize() const
|
||||||
{
|
{
|
||||||
|
if (!m_choice || !m_text)
|
||||||
|
return GetSize();
|
||||||
wxSize size = m_choice->GetBestSize();
|
wxSize size = m_choice->GetBestSize();
|
||||||
|
|
||||||
if ( m_text != NULL )
|
if ( m_text != NULL )
|
||||||
|
Reference in New Issue
Block a user