]> git.saurik.com Git - wxWidgets.git/blobdiff - src/cocoa/checklst.mm
Add some version checks to help compiling on OSX.
[wxWidgets.git] / src / cocoa / checklst.mm
index 1ddc6fc8d1c615712622d3b294198f58b2d5fcb8..36e052101da0147f6f1bf0cdd2cd4ad85c1c3787 100644 (file)
@@ -1,23 +1,43 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        cocoa/checklst.mm
+// Name:        src/cocoa/checklst.mm
 // Purpose:     wxCheckListBox
 // Author:      David Elliott
 // Modified by:
 // Created:     2003/03/18
-// RCS-ID:      $Id
+// RCS-ID:      $Id$
 // Copyright:   (c) 2003 David Elliott
-// Licence:    wxWindows license
+// Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
-#include "wx/app.h"
+#include "wx/wxprec.h"
+
+#if wxUSE_CHECKLISTBOX
+
 #include "wx/checklst.h"
-#include "wx/log.h"
 
-IMPLEMENT_DYNAMIC_CLASS(wxCheckListBox, wxListBox)
+#ifndef WX_PRECOMP
+    #include "wx/log.h"
+    #include "wx/app.h"
+#endif //WX_PRECOMP
+
 BEGIN_EVENT_TABLE(wxCheckListBox, wxCheckListBoxBase)
 END_EVENT_TABLE()
 // WX_IMPLEMENT_COCOA_OWNER(wxCheckListBox,NSButton,NSControl,NSView)
 
+bool wxCheckListBox::Create(wxWindow *parent, wxWindowID winid,
+            const wxPoint& pos,
+            const wxSize& size,
+            const wxArrayString& choices,
+            long style,
+            const wxValidator& validator,
+            const wxString& name)
+{
+    wxCArrayString chs(choices);
+
+    return Create(parent, winid, pos, size, chs.GetCount(), chs.GetStrings(),
+                  style, validator, name);
+}
+
 bool wxCheckListBox::Create(wxWindow *parent, wxWindowID winid,
             const wxPoint& pos,
             const wxSize& size,
@@ -36,16 +56,16 @@ bool wxCheckListBox::Create(wxWindow *parent, wxWindowID winid,
 
 wxCheckListBox::~wxCheckListBox()
 {
-    CocoaRemoveFromParent();
 }
 
-bool wxCheckListBox::IsChecked(size_t item) const
+bool wxCheckListBox::IsChecked(unsigned int item) const
 {
     return false;
 }
 
 
-void wxCheckListBox::Check(size_t item, bool check)
+void wxCheckListBox::Check(unsigned int item, bool check)
 {
 }
 
+#endif