fixed listbox initial size determination
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12710 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
eda40bfc08
commit
13960e3c69
@ -393,8 +393,6 @@ bool wxListBox::Create( wxWindow *parent, wxWindowID id,
|
||||
|
||||
gtk_widget_show( GTK_WIDGET(m_list) );
|
||||
|
||||
SetBestSize( size );
|
||||
|
||||
if ( style & wxLB_SORT )
|
||||
{
|
||||
// this will change DoAppend() behaviour
|
||||
@ -411,6 +409,10 @@ bool wxListBox::Create( wxWindow *parent, wxWindowID id,
|
||||
DoAppend(choices[i]);
|
||||
}
|
||||
|
||||
// call it after appending the strings to the listbox, otherwise it doesn't
|
||||
// work correctly
|
||||
SetBestSize( size );
|
||||
|
||||
m_parent->DoAddChild( this );
|
||||
|
||||
PostCreation();
|
||||
|
@ -393,8 +393,6 @@ bool wxListBox::Create( wxWindow *parent, wxWindowID id,
|
||||
|
||||
gtk_widget_show( GTK_WIDGET(m_list) );
|
||||
|
||||
SetBestSize( size );
|
||||
|
||||
if ( style & wxLB_SORT )
|
||||
{
|
||||
// this will change DoAppend() behaviour
|
||||
@ -411,6 +409,10 @@ bool wxListBox::Create( wxWindow *parent, wxWindowID id,
|
||||
DoAppend(choices[i]);
|
||||
}
|
||||
|
||||
// call it after appending the strings to the listbox, otherwise it doesn't
|
||||
// work correctly
|
||||
SetBestSize( size );
|
||||
|
||||
m_parent->DoAddChild( this );
|
||||
|
||||
PostCreation();
|
||||
|
Loading…
Reference in New Issue
Block a user