diff --git a/src/mac/carbon/listbox.cpp b/src/mac/carbon/listbox.cpp index 6564af7b77..17efb46fab 100644 --- a/src/mac/carbon/listbox.cpp +++ b/src/mac/carbon/listbox.cpp @@ -173,9 +173,12 @@ int wxListBox::DoAppend(const wxString& item) if( wxApp::s_macDefaultEncodingIsPC ) { m_stringArray.Add( wxMacMakeMacStringFromPC( item ) ) ; + m_dataArray.Add( NULL ); } - else + else { m_stringArray.Add( item ) ; + m_dataArray.Add( NULL ); + } m_noItems ++; MacAppend( item ) ; diff --git a/src/mac/listbox.cpp b/src/mac/listbox.cpp index 6564af7b77..17efb46fab 100644 --- a/src/mac/listbox.cpp +++ b/src/mac/listbox.cpp @@ -173,9 +173,12 @@ int wxListBox::DoAppend(const wxString& item) if( wxApp::s_macDefaultEncodingIsPC ) { m_stringArray.Add( wxMacMakeMacStringFromPC( item ) ) ; + m_dataArray.Add( NULL ); } - else + else { m_stringArray.Add( item ) ; + m_dataArray.Add( NULL ); + } m_noItems ++; MacAppend( item ) ;