X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e1673e527f08395de6864b09540162ca409a3c28..6cef0db28018fd2644ee4e38af715872e5242459:/src/mac/carbon/choice.cpp?ds=inline diff --git a/src/mac/carbon/choice.cpp b/src/mac/carbon/choice.cpp index e5f7c54da4..c395a39d19 100644 --- a/src/mac/carbon/choice.cpp +++ b/src/mac/carbon/choice.cpp @@ -50,14 +50,17 @@ bool wxChoice::Create(wxWindow *parent, const wxValidator& validator, const wxString& name ) { - return Create( - parent, id, pos, size, 0, NULL, - style, validator, name ); + if ( !Create( parent, id, pos, size, 0, NULL, style, validator, name ) ) + return false; Append( choices ); if ( !choices.empty() ) SetSelection( 0 ); + + SetInitialSize( size ); + + return true; } bool wxChoice::Create(wxWindow *parent, @@ -136,7 +139,7 @@ int wxChoice::DoInsertItems(const wxArrayStringsAdapter & items, UMAInsertMenuItem(MAC_WXHMENU( m_macPopUpMenuHandle ), items[i], - m_font.GetEncoding(), + GetFont().GetEncoding(), idx); m_datas.Insert( NULL, idx ); AssignNewItemClientData(idx, clientData, i, type);