]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mac/carbon/combobox.cpp
corrected line counts and implemented ShowPosition
[wxWidgets.git] / src / mac / carbon / combobox.cpp
index c3c5660bbf5163b8502539f6e28406182488d670..27aa1a58de3e840e05d6153dc326262a3e011822 100644 (file)
@@ -162,7 +162,10 @@ END_EVENT_TABLE()
 
 wxComboBox::~wxComboBox()
 {
-   // delete the controls now, don't leave them alive even though they would
+    // delete client objects
+    FreeData();
+
+    // delete the controls now, don't leave them alive even though they would
     // still be eventually deleted by our parent - but it will be too late, the
     // user code expects them to be gone now
     if (m_text != NULL) {
@@ -253,6 +256,22 @@ void wxComboBox::DelegateChoice( const wxString& value )
 }
 
 
+bool wxComboBox::Create(wxWindow *parent, wxWindowID id,
+           const wxString& value,
+           const wxPoint& pos,
+           const wxSize& size,
+           const wxArrayString& choices,
+           long style,
+           const wxValidator& validator,
+           const wxString& name)
+{
+    wxCArrayString chs( choices );
+
+    return Create( parent, id, value, pos, size, chs.GetCount(),
+                   chs.GetStrings(), style, validator, name );
+}
+
+
 bool wxComboBox::Create(wxWindow *parent, wxWindowID id,
            const wxString& value,
            const wxPoint& pos,