]>
git.saurik.com Git - wxWidgets.git/blob - samples/editlbox/editlbox.cpp
1 // For compilers that support precompilation, includes "wx/wx.h".
8 // for all others, include the necessary headers (this file is usually all you
9 // need because it includes almost all "standard" wxWidgets headers)
14 #include "wx/editlbox.h"
17 class MyApp
: public wxApp
20 virtual bool OnInit();
28 wxDialog
dlg(NULL
, wxID_ANY
, _("Test dialog"), wxDefaultPosition
, wxDefaultSize
,
29 wxDEFAULT_DIALOG_STYLE
| wxRESIZE_BORDER
);
31 wxSizer
*sizer
= new wxBoxSizer(wxVERTICAL
);
32 sizer
->Add(new wxEditableListBox(&dlg
, wxID_ANY
, _("Match these wildcards:"),
33 wxDefaultPosition
,wxSize(300,200)),
34 1, wxEXPAND
|wxALL
, 10);
38 wxEditableListBox
*lb
= new wxEditableListBox(&dlg
, wxID_ANY
, _("Except:"),
39 wxDefaultPosition
,wxSize(300,200));
46 sizer
->Add(lb
, 1, wxEXPAND
|wxALL
, 10);
50 sizer
->Add(new wxButton(&dlg
, wxID_OK
, _("OK")), 0, wxALIGN_RIGHT
| wxALL
, 10);
51 dlg
.SetSizerAndFit(sizer
);
56 wxString res
= _("'Except' contains these strings:\n\n");
58 for (size_t i
= 0; i
< ar
.GetCount(); i
++)
59 res
<< ar
[i
] << _T("\n");