]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/widgets/listbox.cpp
Move #inclusion of wx/msw/winundef.h for MinGW to afterstd.h.
[wxWidgets.git] / samples / widgets / listbox.cpp
index ca2773d8050d31f74fe5bb3ead924d4e2858ea5e..33d578c86c1f6dd82cb52d0b72ddb70e17524729 100644 (file)
@@ -28,6 +28,7 @@
 #ifndef WX_PRECOMP
     #include "wx/log.h"
 
+    #include "wx/bitmap.h"
     #include "wx/button.h"
     #include "wx/checkbox.h"
     #include "wx/combobox.h"
@@ -351,7 +352,7 @@ void ListboxWidgetsPage::CreateLbox()
             items.Add(m_lbox->GetString(n));
         }
 
-        m_sizerLbox->Remove(m_lbox);
+        m_sizerLbox->Detach( m_lbox );
         delete m_lbox;
     }
 
@@ -428,7 +429,7 @@ void ListboxWidgetsPage::OnButtonClear(wxCommandEvent& event)
 
 void ListboxWidgetsPage::OnButtonAdd(wxCommandEvent& event)
 {
-    static size_t s_item = 0;
+    static unsigned int s_item = 0;
 
     wxString s = m_textAdd->GetValue();
     if ( !m_textAdd->IsModified() )
@@ -443,7 +444,7 @@ void ListboxWidgetsPage::OnButtonAdd(wxCommandEvent& event)
 void ListboxWidgetsPage::OnButtonAddMany(wxCommandEvent& WXUNUSED(event))
 {
     // "many" means 1000 here
-    for ( size_t n = 0; n < 1000; n++ )
+    for ( unsigned int n = 0; n < 1000; n++ )
     {
         m_lbox->Append(wxString::Format(_T("item #%u"), n));
     }