X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c1daf25293569ffc68e4afb26338fba4bc29cff4..2d5efafe74f3788bfd3b3d8b1e8e13135a595ed5:/samples/widgets/itemcontainer.h?ds=sidebyside diff --git a/samples/widgets/itemcontainer.h b/samples/widgets/itemcontainer.h index baa1982bb8..06b1231da3 100644 --- a/samples/widgets/itemcontainer.h +++ b/samples/widgets/itemcontainer.h @@ -4,31 +4,20 @@ // Purpose: Part of the widgets sample showing wxComboBox // Created: 20.07.07 // Id: $Id$ -// License: wxWindows license +// License: wxWindows licence ///////////////////////////////////////////////////////////////////////////// #ifndef _WX_SAMPLE_WIDGETS_ITEMCONTAINER_H_ #define _WX_SAMPLE_WIDGETS_ITEMCONTAINER_H_ -// for compilers that support precompilation, includes "wx/wx.h". -#include "wx/wxprec.h" - #include "widgets.h" -// define a common base class for sorted and normal string arrays -#if wxUSE_STL - typedef wxBaseArrayStringBase wxMaybeSortedArrayString; -#else - // in non-STL build wxSortedArrayString derives from wxArrayString - typedef wxArrayString wxMaybeSortedArrayString; -#endif - class ItemContainerWidgetsPage : public WidgetsPage { public: ItemContainerWidgetsPage(WidgetsBookCtrl *book, wxImageList *image_list, - char* icon[]); + const char *const icon[]); virtual ~ItemContainerWidgetsPage(); void OnButtonTestItemContainer(wxCommandEvent& event); @@ -37,7 +26,7 @@ public: private: void StartTest(const wxString& label); - void EndTest(const wxMaybeSortedArrayString& result); + void EndTest(const wxArrayString& result); // Track client data in wxItemContainer instances wxClientData* CreateClientData(int value); @@ -48,7 +37,9 @@ private: bool VerifyAllClientDataDestroyed(); bool VerifyClientData(wxUIntPtr i, const wxString& str); - wxString DumpContainerData(const wxMaybeSortedArrayString& expected) const; + wxString DumpContainerData(const wxArrayString& expected) const; + + static wxArrayString MakeArray(const wxSortedArrayString& sorted); wxArrayString m_items; wxSortedArrayString m_itemsSorted;