wxComboBox *combo = wxDynamicCast(control, wxComboBox);
if ( combo )
{
- WXHWND hwndComboEdit = combo->GetEditHWND();
+ WXHWND hwndComboEdit = combo->GetWindowStyle() & wxCB_READONLY
+ ? combo->GetHWND()
+ : combo->GetEditHWND();
if ( hwndComboEdit )
{
Add(hwndComboEdit);
}
- //else: it's ok for a combo to be read only, of course
}
}