- PreCreation( parent, id, pos, size, style, name );
-
-#if wxUSE_VALIDATORS
- SetValidator( validator );
-#endif
+ wxSize newSize( size );
+ if (newSize.x == -1)
+ newSize.x = 80;
+ if (newSize.y == -1)
+ newSize.y = 26;
+ if (newSize.y > 30)
+ newSize.y = 30;
+
+ if (!PreCreation( parent, pos, newSize ) ||
+ !CreateBase( parent, id, pos, size, style, validator, name ))
+ {
+ wxFAIL_MSG( wxT("wxComboBox creation failed") );
+ return FALSE;
+ }