]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/ctrlsub.cpp
Platform and compiler-specific checking for MSW and Mac now done
[wxWidgets.git] / src / common / ctrlsub.cpp
index 1c7e18ea27ac807f9643e750732326cd60344ddb..975812f8d44749c7b385f2105b83775082ca8722 100644 (file)
@@ -57,6 +57,38 @@ wxString wxItemContainer::GetStringSelection() const
     return s;
 }
 
     return s;
 }
 
+// ----------------------------------------------------------------------------
+// appending items
+// ----------------------------------------------------------------------------
+
+void wxItemContainer::Append(const wxArrayString& strings)
+{
+    size_t count = strings.GetCount();
+    for ( size_t n = 0; n < count; n++ )
+    {
+        Append(strings[n]);
+    }
+}
+
+int wxItemContainer::Insert(const wxString& item, int pos, void *clientData)
+{
+    int n = DoInsert(item, pos);
+    if ( n != wxNOT_FOUND )
+        SetClientData(n, clientData);
+
+    return n;
+}
+
+int
+wxItemContainer::Insert(const wxString& item, int pos, wxClientData *clientData)
+{
+    int n = DoInsert(item, pos);
+    if ( n != wxNOT_FOUND )
+        SetClientObject(n, clientData);
+
+    return n;
+}
+
 // ----------------------------------------------------------------------------
 // client data
 // ----------------------------------------------------------------------------
 // ----------------------------------------------------------------------------
 // client data
 // ----------------------------------------------------------------------------
@@ -109,4 +141,9 @@ void *wxItemContainer::GetClientData(int n) const
     return DoGetItemClientData(n);
 }
 
     return DoGetItemClientData(n);
 }
 
+wxControlWithItems::~wxControlWithItems()
+{
+    // this destructor is required for Darwin
+}
+
 #endif // wxUSE_CONTROLS
 #endif // wxUSE_CONTROLS