- wxTheFontMapper: use wxFontMapper::Get() instead
- wxStringHashTable: use wxHashMap instead
- wxHashTableLong: use wxHashMap instead
-- wxArrayString::GetStringArray: no replacement
+- wxArrayString::GetStringArray: use wxCArrayString or alternative wxWindows
+ methods taking wxArrayString
- wxArrayString::Remove(index, count): use RemoveAt instead
- wxTreeItemId conversion to long is deprecated and shouldn't be used
- [MSW only] wxWindow::GetUseCtl3D(), GetTransparentBackground() and
wxSize (Wlodzimierz Skiba)
- intermediate wxIPaddress class added to prepare for
wxIPV6address (Ray Gilbert)
+- added overloaded constructors and Create() methods taking wxArrayString
+ for wxChoice, wxComboBox, wxListBox, wxRadioBox, wxCheckListBox,
+ wxSingleChoiceDialog, wxMultipleChoiceDialog
All (GUI):
// constructors and destructor
// default ctor
- wxArrayString()
- : m_nSize(0), m_nCount(0), m_pItems(NULL), m_autoSort(FALSE)
- { Init(FALSE); }
- // if autoSort is TRUE, the array is always sorted (in alphabetical order)
+ wxArrayString() { Init(false); }
+ // if autoSort is true, the array is always sorted (in alphabetical order)
//
// NB: the reason for using int and not bool is that like this we can avoid
// using this ctor for implicit conversions from "const char *" (which
//
// of course, using explicit would be even better - if all compilers
// supported it...
- wxArrayString(int autoSort)
- : m_nSize(0), m_nCount(0), m_pItems(NULL), m_autoSort(FALSE)
- { Init(autoSort != 0); }
+ wxArrayString(int autoSort) { Init(autoSort != 0); }
// copy ctor
wxArrayString(const wxArrayString& array);
// assignment operator
// take one in their ctor. You must delete[] it yourself
// once you are done with it. Will return NULL if the
// ArrayString was empty.
+#if WXWIN_COMPATIBILITY_2_4
wxString* GetStringArray() const;
+#endif
// item management
// Search the element in the array, starting from the beginning if
- // bFromEnd is FALSE or from end otherwise. If bCase, comparison is case
+ // bFromEnd is false or from end otherwise. If bCase, comparison is case
// sensitive (default). Returns index of the first item matched or
// wxNOT_FOUND
- int Index (const wxChar *sz, bool bCase = TRUE, bool bFromEnd = FALSE) const;
+ int Index (const wxChar *sz, bool bCase = true, bool bFromEnd = false) const;
// add new element at the end (if the array is not sorted), return its
// index
size_t Add(const wxString& str, size_t nInsert = 1);
// sorting
// sort array elements in alphabetical order (or reversed alphabetical
- // order if reverseOrder parameter is TRUE)
- void Sort(bool reverseOrder = FALSE);
+ // order if reverseOrder parameter is true)
+ void Sort(bool reverseOrder = false);
// sort array elements using specified comparaison function
void Sort(CompareFunction compareFunction);
void Sort(CompareFunction2 compareFunction);
bool operator !=(const itor& it) { return m_ptr != it.m_ptr; }
};
+ wxArrayString(const_iterator first, const_iterator last)
+ { Init(false); assign(first, last); }
+ wxArrayString(size_type n, const_reference v) { Init(false); assign(n, v); }
void assign(const_iterator first, const_iterator last);
void assign(size_type n, const_reference v)
{ clear(); Add(v, n); }
wxChar **m_pItems; // pointer to data
- bool m_autoSort; // if TRUE, keep the array always sorted
+ bool m_autoSort; // if true, keep the array always sorted
};
class WXDLLIMPEXP_BASE wxSortedArrayString : public wxArrayString
{
public:
- wxSortedArrayString() : wxArrayString(TRUE)
+ wxSortedArrayString() : wxArrayString(true)
{ }
- wxSortedArrayString(const wxArrayString& array) : wxArrayString(TRUE)
+ wxSortedArrayString(const wxArrayString& array) : wxArrayString(true)
{ Copy(array); }
};
#endif // !wxUSE_STL
+// this class provides a temporary wxString* from a
+// wxArrayString
+class WXDLLIMPEXP_BASE wxCArrayString
+{
+public:
+ wxCArrayString( const wxArrayString& array )
+ : m_array( array ), m_strings( NULL )
+ { }
+ ~wxCArrayString() { delete[] m_strings; }
+
+ size_t GetCount() const { return m_array.GetCount(); }
+ wxString* GetStrings()
+ {
+ if( m_strings ) return m_strings;
+ size_t count = m_array.GetCount();
+ m_strings = new wxString[count];
+ for( size_t i = 0; i < count; ++i )
+ m_strings[i] = m_array[i];
+ return m_strings;
+ }
+private:
+ const wxArrayString& m_array;
+ wxString* m_strings;
+};
+
#endif
{
Create(parent, winid, pos, size, n, choices, style, validator, name);
}
+ wxCheckListBox(wxWindow *parent, wxWindowID winid,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr)
+ {
+ Create(parent, winid, pos, size, choices, style, validator, name);
+ }
bool Create(wxWindow *parent, wxWindowID winid,
const wxPoint& pos = wxDefaultPosition,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID winid,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
virtual ~wxCheckListBox();
// ------------------------------------------------------------------------
//#include "wx/cocoa/NSPopUpButton.h"
#include "wx/cocoa/NSMenu.h"
+class WXDLLIMPEXP_BASE wxSortedArrayString;
+
// ========================================================================
// wxChoice
// ========================================================================
Init();
Create(parent, winid, pos, size, n, choices, style, validator, name);
}
+ wxChoice(wxWindow *parent, wxWindowID winid,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr)
+ {
+ Init();
+ Create(parent, winid, pos, size, choices, style, validator, name);
+ }
bool Create(wxWindow *parent, wxWindowID winid,
const wxPoint& pos = wxDefaultPosition,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxChoiceNameStr);
+ bool Create(wxWindow *parent, wxWindowID winid,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr);
virtual ~wxChoice();
protected:
void Init();
{
Create(parent, winid, value, pos, size, n, choices, style, validator, name);
}
+ wxComboBox(wxWindow *parent, wxWindowID winid,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr)
+ {
+ Create(parent, winid, value, pos, size, choices, style,
+ validator, name);
+ }
bool Create(wxWindow *parent, wxWindowID winid,
const wxString& value = wxEmptyString,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxComboBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID winid,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr);
virtual ~wxComboBox();
// ------------------------------------------------------------------------
{
Create(parent, winid, pos, size, n, choices, style, validator, name);
}
+ wxListBox(wxWindow *parent, wxWindowID winid,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr)
+ {
+ Create(parent, winid, pos, size, choices, style, validator, name);
+ }
bool Create(wxWindow *parent, wxWindowID winid,
const wxPoint& pos = wxDefaultPosition,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID winid,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
virtual ~wxListBox();
// ------------------------------------------------------------------------
{
Create(parent, winid, title, pos, size, n, choices, majorDim, style, validator, name);
}
+ wxRadioBox(wxWindow *parent, wxWindowID winid,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 0,
+ long style = 0, const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr)
+ {
+ Create(parent, winid, title, pos, size, choices, majorDim, style, validator, name);
+ }
bool Create(wxWindow *parent, wxWindowID winid,
const wxString& title,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxRadioBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID winid,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 0,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr);
virtual ~wxRadioBox();
// ------------------------------------------------------------------------
bool operator !=(const itor& it) { return m_ptr != it.m_ptr; } \
}; \
\
+ name(size_type n, const_reference v) { assign(n, v); } \
+ name(const_iterator first, const_iterator last) \
+ { assign(first, last); } \
void assign(const_iterator first, const_iterator last) \
{ base::assign((bconst_iterator)first, (bconst_iterator)last); } \
void assign(size_type n, const_reference v) \
(void)Create(parent, message, caption, n, choices,
styleDlg, pos, styleLbox);
}
+ wxAnyChoiceDialog(wxWindow *parent,
+ const wxString& message,
+ const wxString& caption,
+ const wxArrayString& choices,
+ long styleDlg = wxCHOICEDLG_STYLE,
+ const wxPoint& pos = wxDefaultPosition,
+ long styleLbox = wxLB_ALWAYS_SB)
+ {
+ (void)Create(parent, message, caption, choices,
+ styleDlg, pos, styleLbox);
+ }
bool Create(wxWindow *parent,
const wxString& message,
long styleDlg = wxCHOICEDLG_STYLE,
const wxPoint& pos = wxDefaultPosition,
long styleLbox = wxLB_ALWAYS_SB);
+ bool Create(wxWindow *parent,
+ const wxString& message,
+ const wxString& caption,
+ const wxArrayString& choices,
+ long styleDlg = wxCHOICEDLG_STYLE,
+ const wxPoint& pos = wxDefaultPosition,
+ long styleLbox = wxLB_ALWAYS_SB);
protected:
wxListBox *m_listbox;
char **clientData = (char **)NULL,
long style = wxCHOICEDLG_STYLE,
const wxPoint& pos = wxDefaultPosition);
+ wxSingleChoiceDialog(wxWindow *parent,
+ const wxString& message,
+ const wxString& caption,
+ const wxArrayString& choices,
+ char **clientData = (char **)NULL,
+ long style = wxCHOICEDLG_STYLE,
+ const wxPoint& pos = wxDefaultPosition);
bool Create(wxWindow *parent,
const wxString& message,
char **clientData = (char **)NULL,
long style = wxCHOICEDLG_STYLE,
const wxPoint& pos = wxDefaultPosition);
+ bool Create(wxWindow *parent,
+ const wxString& message,
+ const wxString& caption,
+ const wxArrayString& choices,
+ char **clientData = (char **)NULL,
+ long style = wxCHOICEDLG_STYLE,
+ const wxPoint& pos = wxDefaultPosition);
void SetSelection(int sel);
int GetSelection() const { return m_selection; }
{
(void)Create(parent, message, caption, n, choices, style, pos);
}
+ wxMultiChoiceDialog(wxWindow *parent,
+ const wxString& message,
+ const wxString& caption,
+ const wxArrayString& choices,
+ long style = wxCHOICEDLG_STYLE,
+ const wxPoint& pos = wxDefaultPosition)
+ {
+ (void)Create(parent, message, caption, choices, style, pos);
+ }
bool Create(wxWindow *parent,
const wxString& message,
const wxString *choices,
long style = wxCHOICEDLG_STYLE,
const wxPoint& pos = wxDefaultPosition);
+ bool Create(wxWindow *parent,
+ const wxString& message,
+ const wxString& caption,
+ const wxArrayString& choices,
+ long style = wxCHOICEDLG_STYLE,
+ const wxPoint& pos = wxDefaultPosition);
void SetSelections(const wxArrayInt& selections);
wxArrayInt GetSelections() const { return m_selections; }
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ wxCheckListBox(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
bool IsChecked( int index ) const;
void Check( int index, bool check = TRUE );
#endif
class WXDLLIMPEXP_BASE wxSortedArrayString;
+class WXDLLIMPEXP_BASE wxArrayString;
//-----------------------------------------------------------------------------
// wxChoice
Create(parent, id, pos, size, n, choices, style, validator, name);
}
+ wxChoice( wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr )
+ {
+ m_strings = (wxSortedArrayString *)NULL;
+
+ Create(parent, id, pos, size, choices, style, validator, name);
+ }
~wxChoice();
bool Create( wxWindow *parent, wxWindowID id,
const wxPoint& pos = wxDefaultPosition,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxChoiceNameStr );
+ bool Create( wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr );
// implement base class pure virtuals
void Delete(int n);
{
Create(parent, id, value, pos, size, n, choices, style, validator, name);
}
+ inline wxComboBox(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr)
+ {
+ Create(parent, id, value, pos, size, choices, style, validator, name);
+ }
~wxComboBox();
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxComboBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr);
void Clear();
void Delete( int n );
#endif // wxUSE_CHECKLISTBOX
Create(parent, id, pos, size, n, choices, style, validator, name);
}
+ wxListBox( wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr )
+ {
+#if wxUSE_CHECKLISTBOX
+ m_hasCheckBoxes = FALSE;
+#endif // wxUSE_CHECKLISTBOX
+ Create(parent, id, pos, size, choices, style, validator, name);
+ }
virtual ~wxListBox();
bool Create(wxWindow *parent, wxWindowID id,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
// implement base class pure virtuals
virtual void Clear();
Create( parent, id, title, pos, size, n, choices, majorDim, style, val, name );
}
+ wxRadioBox(wxWindow *parent,
+ wxWindowID id,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 1,
+ long style = wxRA_HORIZONTAL,
+ const wxValidator& val = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr)
+ {
+ Init();
+
+ Create( parent, id, title, pos, size, choices, majorDim, style, val, name );
+ }
virtual ~wxRadioBox();
bool Create(wxWindow *parent,
long style = wxRA_HORIZONTAL,
const wxValidator& val = wxDefaultValidator,
const wxString& name = wxRadioBoxNameStr);
+ bool Create(wxWindow *parent,
+ wxWindowID id,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 0,
+ long style = wxRA_HORIZONTAL,
+ const wxValidator& val = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr);
int FindString( const wxString& s) const;
void SetSelection( int n );
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ wxCheckListBox(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
bool IsChecked( int index ) const;
void Check( int index, bool check = TRUE );
#endif
class WXDLLIMPEXP_BASE wxSortedArrayString;
+class WXDLLIMPEXP_BASE wxArrayString;
//-----------------------------------------------------------------------------
// wxChoice
Create(parent, id, pos, size, n, choices, style, validator, name);
}
+ wxChoice( wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr )
+ {
+ m_strings = (wxSortedArrayString *)NULL;
+
+ Create(parent, id, pos, size, choices, style, validator, name);
+ }
~wxChoice();
bool Create( wxWindow *parent, wxWindowID id,
const wxPoint& pos = wxDefaultPosition,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxChoiceNameStr );
+ bool Create( wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr );
// implement base class pure virtuals
void Delete(int n);
{
Create(parent, id, value, pos, size, n, choices, style, validator, name);
}
+ inline wxComboBox(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr)
+ {
+ Create(parent, id, value, pos, size, choices, style, validator, name);
+ }
~wxComboBox();
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxComboBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr);
void Clear();
void Delete( int n );
#endif // wxUSE_CHECKLISTBOX
Create(parent, id, pos, size, n, choices, style, validator, name);
}
+ wxListBox( wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr )
+ {
+#if wxUSE_CHECKLISTBOX
+ m_hasCheckBoxes = FALSE;
+#endif // wxUSE_CHECKLISTBOX
+ Create(parent, id, pos, size, choices, style, validator, name);
+ }
virtual ~wxListBox();
bool Create(wxWindow *parent, wxWindowID id,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
// implement base class pure virtuals
virtual void Clear();
Create( parent, id, title, pos, size, n, choices, majorDim, style, val, name );
}
+ wxRadioBox(wxWindow *parent,
+ wxWindowID id,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 1,
+ long style = wxRA_HORIZONTAL,
+ const wxValidator& val = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr)
+ {
+ Init();
+
+ Create( parent, id, title, pos, size, choices, majorDim, style, val, name );
+ }
virtual ~wxRadioBox();
bool Create(wxWindow *parent,
long style = wxRA_HORIZONTAL,
const wxValidator& val = wxDefaultValidator,
const wxString& name = wxRadioBoxNameStr);
+ bool Create(wxWindow *parent,
+ wxWindowID id,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 0,
+ long style = wxRA_HORIZONTAL,
+ const wxValidator& val = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr);
int FindString( const wxString& s) const;
void SetSelection( int n );
Create(parent, id, pos, size, nStrings, choices, style, validator, name);
}
+ wxCheckListBox(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr)
+ {
+ Init();
+
+ Create(parent, id, pos, size, choices, style, validator, name);
+ }
bool Create(wxWindow *parent,
wxWindowID id,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ bool Create(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
// items may be checked
bool IsChecked(size_t uiIndex) const;
#include "wx/control.h"
- #include "wx/dynarray.h"
+#include "wx/dynarray.h"
+#include "wx/arrstr.h"
WXDLLEXPORT_DATA(extern const wxChar*) wxChoiceNameStr;
{
Create(parent, id, pos, size, n, choices, style, validator, name);
}
+ wxChoice(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr)
+ {
+ Create(parent, id, pos, size, choices, style, validator, name);
+ }
bool Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos = wxDefaultPosition,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxChoiceNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr);
// implement base class pure virtuals
virtual int DoAppend(const wxString& item);
{
Create(parent, id, value, pos, size, n, choices, style, validator, name);
}
+ inline wxComboBox(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr)
+ {
+ Create(parent, id, value, pos, size, choices, style, validator, name);
+ }
bool Create(wxWindow *parent, wxWindowID id,
const wxString& value = wxEmptyString,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxComboBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr);
// List functions
virtual void Delete(int n);
// simple types
// ----------------------------------------------------------------------------
#include "wx/dynarray.h"
-
+#include "wx/arrstr.h"
#if wxUSE_OWNER_DRAWN
class WXDLLEXPORT wxOwnerDrawn;
{
Create(parent, id, pos, size, n, choices, style, validator, name);
}
+ wxListBox(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr)
+ {
+ Create(parent, id, pos, size, choices, style, validator, name);
+ }
bool Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos = wxDefaultPosition,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
virtual ~wxListBox();
virtual void Refresh(bool eraseBack = TRUE, const wxRect *rect = NULL);
class WXDLLEXPORT wxFrame;
+#include "wx/arrstr.h"
+
// ----------------------------------------------------------------------------
// Menu
// ----------------------------------------------------------------------------
{
Create(parent, id, title, pos, size, n, choices, majorDim, style, val, name);
}
+ inline wxRadioBox(wxWindow *parent, wxWindowID id, const wxString& title,
+ const wxPoint& pos, const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 0, long style = wxRA_HORIZONTAL,
+ const wxValidator& val = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr)
+ {
+ Create(parent, id, title, pos, size, choices,
+ majorDim, style, val, name);
+ }
~wxRadioBox();
bool Create(wxWindow *parent, wxWindowID id, const wxString& title,
const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize,
int n = 0, const wxString choices[] = NULL,
int majorDim = 0, long style = wxRA_HORIZONTAL,
const wxValidator& val = wxDefaultValidator, const wxString& name = wxRadioBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id, const wxString& title,
+ const wxPoint& pos, const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 0, long style = wxRA_HORIZONTAL,
+ const wxValidator& val = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr);
// Specific functions (in wxWindows2 reference)
virtual void SetSelection(int item);
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ wxCheckListBox(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
+
bool Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
+
// items may be checked
bool IsChecked(size_t uiIndex) const;
void Check(size_t uiIndex, bool bCheck = TRUE);
Create(parent, id, pos, size, n, choices, style, validator, name);
}
+ wxChoice(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr)
+ {
+ Init();
+ Create(parent, id, pos, size, choices, style, validator, name);
+ }
+
bool Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxChoiceNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr);
+
// implementation of wxControlWithItems
virtual int GetCount() const;
virtual int DoAppend(const wxString& item);
style, validator, name);
}
+ inline wxComboBox(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr)
+ {
+ m_inSetSelection = false;
+ Create(parent, id, value, pos, size, choices,
+ style, validator, name);
+ }
+
bool Create(wxWindow *parent, wxWindowID id,
const wxString& value = wxEmptyString,
const wxPoint& pos = wxDefaultPosition,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxComboBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr);
+
// implementation of wxControlWithItems
virtual int DoAppend(const wxString& item);
virtual int DoInsert(const wxString& item, int pos);
Create(parent, id, pos, size, n, choices, style, validator, name);
}
+ wxListBox(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr)
+ {
+ Create(parent, id, pos, size, choices, style, validator, name);
+ }
+
bool Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
+
~wxListBox();
// implementation of wxControlWithItems
wxMenuBar() { Init(); }
wxMenuBar(long WXUNUSED(style)) { Init(); }
wxMenuBar(int n, wxMenu *menus[], const wxString titles[]);
+ wxMenuBar(int n, wxMenu *menus[], const wxArrayString& titles);
virtual ~wxMenuBar();
// implement base class (pure) virtuals
majorDim, style, val, name);
}
+ wxRadioBox(wxWindow *parent, wxWindowID id, const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 0, long style = wxRA_HORIZONTAL,
+ const wxValidator& val = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr)
+ {
+ Init();
+
+ Create(parent, id, title, pos, size, choices,
+ majorDim, style, val, name);
+ }
+
~wxRadioBox();
bool Create(wxWindow *parent, wxWindowID id, const wxString& title,
const wxValidator& val = wxDefaultValidator,
const wxString& name = wxRadioBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id, const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 0, long style = wxRA_HORIZONTAL,
+ const wxValidator& val = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr);
+
int FindString(const wxString& s) const;
void SetSelection(int N);
int GetSelection() const;
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ wxCheckListBox(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
bool Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos = wxDefaultPosition,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
// override base class virtuals
virtual void Delete(int n);
{
Create(parent, id, pos, size, n, choices, style, validator, name);
}
+ wxChoice(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr)
+ {
+ Create(parent, id, pos, size, choices, style, validator, name);
+ }
bool Create(wxWindow *parent,
wxWindowID id,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxChoiceNameStr);
+ bool Create(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr);
// implement base class pure virtuals
virtual int DoAppend(const wxString& item);
{
Create(parent, id, value, pos, size, n, choices, style, validator, name);
}
+ wxComboBox(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr)
+ {
+ Create(parent, id, value, pos, size, choices, style, validator, name);
+ }
bool Create(wxWindow *parent,
wxWindowID id,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxComboBoxNameStr);
+ bool Create(wxWindow *parent,
+ wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr);
// List functions: see wxChoice
{
Create(parent, id, pos, size, n, choices, style, validator, name);
}
+ wxListBox(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr)
+ {
+ Create(parent, id, pos, size, choices, style, validator, name);
+ }
bool Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos = wxDefaultPosition,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
virtual ~wxListBox();
(void)Create(parent, id, title, pos, size, n, choices, majorDim,
style, val, name);
}
+ wxRadioBox(wxWindow *parent,
+ wxWindowID id,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 0,
+ long style = wxRA_HORIZONTAL,
+ const wxValidator& val = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr)
+ {
+ (void)Create(parent, id, title, pos, size, choices, majorDim,
+ style, val, name);
+ }
~wxRadioBox();
long style = wxRA_HORIZONTAL,
const wxValidator& val = wxDefaultValidator,
const wxString& name = wxRadioBoxNameStr);
+ bool Create(wxWindow *parent,
+ wxWindowID id,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 0,
+ long style = wxRA_HORIZONTAL,
+ const wxValidator& val = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr);
// implement the radiobox interface
virtual void SetSelection(int n);
,const wxValidator& rValidator = wxDefaultValidator
,const wxString& rsName = wxListBoxNameStr
);
+ wxCheckListBox( wxWindow* pParent
+ ,wxWindowID vId
+ ,const wxPoint& rPos
+ ,const wxSize& vSize
+ ,const wxArrayString& asChoices
+ ,long lStyle = 0
+ ,const wxValidator& rValidator = wxDefaultValidator
+ ,const wxString& rsName = wxListBoxNameStr
+ );
//
// Override base class virtuals
);
}
+ inline wxChoice( wxWindow* pParent
+ ,wxWindowID vId
+ ,const wxPoint& rPos
+ ,const wxSize& rSize
+ ,const wxArrayString& asChoices
+ ,long lStyle = 0
+ ,const wxValidator& rValidator = wxDefaultValidator
+ ,const wxString& rsName = wxChoiceNameStr
+ )
+ {
+ Create( pParent
+ ,vId
+ ,rPos
+ ,rSize
+ ,asChoices
+ ,lStyle
+ ,rValidator
+ ,rsName
+ );
+ }
+
bool Create( wxWindow* pParent
,wxWindowID vId
,const wxPoint& rPos = wxDefaultPosition
,const wxString& rsName = wxChoiceNameStr
);
+ bool Create( wxWindow* pParent
+ ,wxWindowID vId
+ ,const wxPoint& rPos
+ ,const wxSize& rSize
+ ,const wxArrayString& asChoices
+ ,long lStyle = 0
+ ,const wxValidator& rValidator = wxDefaultValidator
+ ,const wxString& rsName = wxChoiceNameStr
+ );
+
//
// Implement base class virtuals
//
);
}
+ inline wxComboBox( wxWindow* pParent
+ ,wxWindowID vId
+ ,const wxString& rsValue
+ ,const wxPoint& rPos
+ ,const wxSize& rSize
+ ,const wxArrayString& asChoices
+ ,long lStyle = 0
+ ,const wxValidator& rValidator = wxDefaultValidator
+ ,const wxString& rsName = wxComboBoxNameStr
+ )
+ {
+ Create( pParent
+ ,vId
+ ,rsValue
+ ,rPos
+ ,rSize
+ ,asChoices
+ ,lStyle
+ ,rValidator
+ ,rsName
+ );
+ }
+
bool Create( wxWindow* pParent
,wxWindowID vId
,const wxString& rsValue = wxEmptyString
,const wxString& rsName = wxComboBoxNameStr
);
+ bool Create( wxWindow* pParent
+ ,wxWindowID vId
+ ,const wxString& rsValue
+ ,const wxPoint& rPos
+ ,const wxSize& rSize
+ ,const wxArrayString& asChoices
+ ,long lStyle = 0
+ ,const wxValidator& rValidator = wxDefaultValidator
+ ,const wxString& rsName = wxComboBoxNameStr
+ );
+
//
// List functions: see wxChoice
//
,rsName
);
}
+ wxListBox( wxWindow* pParent
+ ,wxWindowID vId
+ ,const wxPoint& rPos
+ ,const wxSize& rSize
+ ,const wxArrayString& asChoices
+ ,long lStyle = 0
+ ,const wxValidator& rValidator = wxDefaultValidator
+ ,const wxString& rsName = wxListBoxNameStr)
+ {
+ Create( pParent
+ ,vId
+ ,rPos
+ ,rSize
+ ,asChoices
+ ,lStyle
+ ,rValidator
+ ,rsName
+ );
+ }
bool Create( wxWindow* pParent
,wxWindowID vId
,const wxValidator& rValidator = wxDefaultValidator
,const wxString& rsName = wxListBoxNameStr
);
+ bool Create( wxWindow* pParent
+ ,wxWindowID vId
+ ,const wxPoint& rPos
+ ,const wxSize& rSize
+ ,const wxArrayString& asChoices
+ ,long lStyle = 0
+ ,const wxValidator& rValidator = wxDefaultValidator
+ ,const wxString& rsName = wxListBoxNameStr
+ );
virtual ~wxListBox();
);
}
+ inline wxRadioBox( wxWindow* pParent
+ ,wxWindowID vId
+ ,const wxString& rsTitle
+ ,const wxPoint& rPos
+ ,const wxSize& rSize
+ ,const wxArrayString& asChoices
+ ,int nMajorDim = 0
+ ,long lStyle = wxRA_HORIZONTAL
+ ,const wxValidator& rVal = wxDefaultValidator
+ ,const wxString& rsName = wxRadioBoxNameStr
+ )
+ {
+ Create( pParent
+ ,vId
+ ,rsTitle
+ ,rPos
+ ,rSize
+ ,asChoices
+ ,nMajorDim
+ ,lStyle
+ ,rVal
+ ,rsName
+ );
+ }
+
~wxRadioBox();
bool Create( wxWindow* pParent
,const wxString& rsName = wxRadioBoxNameStr
);
+ bool Create( wxWindow* pParent
+ ,wxWindowID vId
+ ,const wxString& rsTitle
+ ,const wxPoint& rPos
+ ,const wxSize& rSize
+ ,const wxArrayString& asChoices
+ ,int nMajorDim = 0
+ ,long lStyle = wxRA_HORIZONTAL
+ ,const wxValidator& rVal = wxDefaultValidator
+ ,const wxString& rsName = wxRadioBoxNameStr
+ );
+
void Command(wxCommandEvent& rEvent);
bool ContainsHWND(WXHWND hWnd) const;
virtual bool Enable(bool bEnable = TRUE);
Create(parent, id, pos, size, nStrings, choices, style, validator, name);
}
+ wxCheckListBox(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
bool Create(wxWindow *parent,
wxWindowID id,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ bool Create(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
// implement check list box methods
virtual bool IsChecked(size_t item) const;
{
Create(parent, id, pos, size, n, choices, style, validator, name);
}
+ wxChoice(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr);
bool Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos = wxDefaultPosition,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxChoiceNameStr);
+ bool Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxChoiceNameStr);
private:
void OnComboBox(wxCommandEvent &event);
(void)Create(parent, id, value, pos, size, n, choices,
style, validator, name);
}
+ wxComboBox(wxWindow *parent,
+ wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr);
bool Create(wxWindow *parent,
wxWindowID id,
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxComboBoxNameStr);
-
+ bool Create(wxWindow *parent,
+ wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxComboBoxNameStr);
virtual ~wxComboBox();
Create(parent, id, pos, size, n, choices, style, validator, name);
}
+ wxListBox(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr );
virtual ~wxListBox();
long style = 0,
const wxValidator& validator = wxDefaultValidator,
const wxString& name = wxListBoxNameStr);
+ bool Create(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style = 0,
+ const wxValidator& validator = wxDefaultValidator,
+ const wxString& name = wxListBoxNameStr);
// implement the listbox interface defined by wxListBoxBase
virtual void Clear();
(void)Create(parent, id, title, pos, size, n, choices,
majorDim, style, val, name);
}
+ wxRadioBox(wxWindow *parent,
+ wxWindowID id,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 0,
+ long style = wxRA_SPECIFY_COLS,
+ const wxValidator& val = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr);
bool Create(wxWindow *parent,
wxWindowID id,
long style = wxRA_SPECIFY_COLS,
const wxValidator& val = wxDefaultValidator,
const wxString& name = wxRadioBoxNameStr);
+ bool Create(wxWindow *parent,
+ wxWindowID id,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim = 0,
+ long style = wxRA_SPECIFY_COLS,
+ const wxValidator& val = wxDefaultValidator,
+ const wxString& name = wxRadioBoxNameStr);
virtual ~wxRadioBox();
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,
#include "wx/log.h"
#include "wx/app.h"
#include "wx/choice.h"
+ #include "wx/arrstr.h"
#endif //WX_PRECOMP
#include "wx/cocoa/string.h"
m_sortedStrings = NULL;
}
+bool wxChoice::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 wxChoice::Create(wxWindow *parent, wxWindowID winid,
const wxPoint& pos,
const wxSize& size,
END_EVENT_TABLE()
// WX_IMPLEMENT_COCOA_OWNER(wxComboBox,NSComboBox,NSTextField,NSView)
+bool wxComboBox::Create(wxWindow *parent, wxWindowID winid,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, winid, value, pos, size, chs.GetCount(),
+ chs.GetStrings(), style, validator, name);
+}
+
bool wxComboBox::Create(wxWindow *parent, wxWindowID winid,
const wxString& value,
const wxPoint& pos,
END_EVENT_TABLE()
WX_IMPLEMENT_COCOA_OWNER(wxListBox,NSTableView,NSControl,NSView)
+bool wxListBox::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 wxListBox::Create(wxWindow *parent, wxWindowID winid,
const wxPoint& pos,
const wxSize& size,
#ifndef WX_PRECOMP
#include "wx/app.h"
#include "wx/radiobox.h"
+ #include "wx/arrstr.h"
#endif //WX_PRECOMP
#import <AppKit/NSView.h>
END_EVENT_TABLE()
// WX_IMPLEMENT_COCOA_OWNER(wxRadioBox,NSTextField,NSControl,NSView)
+bool wxRadioBox::Create(wxWindow *parent, wxWindowID winid,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim,
+ long style, const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, winid, title, pos, size, chs.GetCount(),
+ chs.GetStrings(), majorDim, style, validator, name);
+}
+
bool wxRadioBox::Create(wxWindow *parent, wxWindowID winid,
const wxString& title,
const wxPoint& pos,
return TRUE;
}
+bool wxAnyChoiceDialog::Create(wxWindow *parent,
+ const wxString& message,
+ const wxString& caption,
+ const wxArrayString& choices,
+ long styleDlg,
+ const wxPoint& pos,
+ long styleLbox)
+{
+ wxCArrayString chs(choices);
+ return Create(parent, message, caption, chs.GetCount(), chs.GetStrings(),
+ styleDlg, pos, styleLbox);
+}
+
// ----------------------------------------------------------------------------
// wxSingleChoiceDialog
// ----------------------------------------------------------------------------
Create(parent, message, caption, n, choices, clientData, style);
}
+wxSingleChoiceDialog::wxSingleChoiceDialog(wxWindow *parent,
+ const wxString& message,
+ const wxString& caption,
+ const wxArrayString& choices,
+ char **clientData,
+ long style,
+ const wxPoint& WXUNUSED(pos))
+{
+ Create(parent, message, caption, choices, clientData, style);
+}
+
bool wxSingleChoiceDialog::Create( wxWindow *parent,
const wxString& message,
const wxString& caption,
return TRUE;
}
+bool wxSingleChoiceDialog::Create( wxWindow *parent,
+ const wxString& message,
+ const wxString& caption,
+ const wxArrayString& choices,
+ char **clientData,
+ long style,
+ const wxPoint& pos )
+{
+ wxCArrayString chs(choices);
+ return Create( parent, message, caption, chs.GetCount(), chs.GetStrings(),
+ clientData, style, pos );
+}
+
// Set the selection
void wxSingleChoiceDialog::SetSelection(int sel)
{
return TRUE;
}
+bool wxMultiChoiceDialog::Create( wxWindow *parent,
+ const wxString& message,
+ const wxString& caption,
+ const wxArrayString& choices,
+ long style,
+ const wxPoint& pos )
+{
+ wxCArrayString chs(choices);
+ return Create( parent, message, caption, chs.GetCount(),
+ chs.GetStrings(), style, pos );
+}
+
void wxMultiChoiceDialog::SetSelections(const wxArrayInt& selections)
{
size_t count = selections.GetCount();
wxWindowID id,
wxEvtHandler* evtHandler)
{
- size_t count = m_choices.GetCount();
- wxString *choices = new wxString[count];
- for ( size_t n = 0; n < count; n++ )
- {
- choices[n] = m_choices[n];
- }
-
m_control = new wxComboBox(parent, id, wxEmptyString,
wxDefaultPosition, wxDefaultSize,
- count, choices,
+ m_choices,
m_allowOthers ? 0 : wxCB_READONLY);
- delete [] choices;
-
wxGridCellEditor::Create(parent, id, evtHandler);
}
wxListBox::Create( parent, id, pos, size, nStrings, choices, style, validator, name );
}
+wxCheckListBox::wxCheckListBox(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name )
+{
+ m_hasCheckBoxes = TRUE;
+ wxListBox::Create( parent, id, pos, size, choices,
+ style, validator, name );
+}
+
bool wxCheckListBox::IsChecked( int index ) const
{
wxCHECK_MSG( m_list != NULL, FALSE, wxT("invalid checklistbox") );
m_strings = (wxSortedArrayString *)NULL;
}
+bool wxChoice::Create( wxWindow *parent, wxWindowID id,
+ const wxPoint &pos, const wxSize &size,
+ const wxArrayString& choices,
+ long style, const wxValidator& validator,
+ const wxString &name )
+{
+ wxCArrayString chs(choices);
+
+ return Create( parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name );
+}
+
bool wxChoice::Create( wxWindow *parent, wxWindowID id,
const wxPoint &pos, const wxSize &size,
int n, const wxString choices[],
#if wxUSE_COMBOBOX
#include "wx/settings.h"
+#include "wx/arrstr.h"
#include "wx/intl.h"
#include "wx/textctrl.h" // for wxEVT_COMMAND_TEXT_UPDATED
EVT_CHAR(wxComboBox::OnChar)
END_EVENT_TABLE()
+bool wxComboBox::Create( wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos, const wxSize& size,
+ const wxArrayString& choices,
+ long style, const wxValidator& validator,
+ const wxString& name )
+{
+ wxCArrayString chs(choices);
+
+ return Create( parent, id, value, pos, size, chs.GetCount(),
+ chs.GetStrings(), style, validator, name );
+}
+
bool wxComboBox::Create( wxWindow *parent, wxWindowID id, const wxString& value,
const wxPoint& pos, const wxSize& size,
int n, const wxString choices[],
#endif // wxUSE_CHECKLISTBOX
}
+bool wxListBox::Create( wxWindow *parent, wxWindowID id,
+ const wxPoint &pos, const wxSize &size,
+ const wxArrayString& choices,
+ long style, const wxValidator& validator,
+ const wxString &name )
+{
+ wxCArrayString chs(choices);
+
+ return Create( parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name );
+}
+
bool wxListBox::Create( wxWindow *parent, wxWindowID id,
const wxPoint &pos, const wxSize &size,
int n, const wxString choices[],
m_lostFocus = FALSE;
}
+bool wxRadioBox::Create( wxWindow *parent, wxWindowID id,
+ const wxString& title,
+ const wxPoint &pos, const wxSize &size,
+ const wxArrayString& choices, int majorDim,
+ long style, const wxValidator& validator,
+ const wxString &name )
+{
+ wxCArrayString chs(choices);
+
+ return Create( parent, id, title, pos, size, chs.GetCount(),
+ chs.GetStrings(), majorDim, style, validator, name );
+}
+
bool wxRadioBox::Create( wxWindow *parent, wxWindowID id, const wxString& title,
const wxPoint &pos, const wxSize &size,
int n, const wxString choices[], int majorDim,
wxListBox::Create( parent, id, pos, size, nStrings, choices, style, validator, name );
}
+wxCheckListBox::wxCheckListBox(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name )
+{
+ m_hasCheckBoxes = TRUE;
+ wxListBox::Create( parent, id, pos, size, choices,
+ style, validator, name );
+}
+
bool wxCheckListBox::IsChecked( int index ) const
{
wxCHECK_MSG( m_list != NULL, FALSE, wxT("invalid checklistbox") );
m_strings = (wxSortedArrayString *)NULL;
}
+bool wxChoice::Create( wxWindow *parent, wxWindowID id,
+ const wxPoint &pos, const wxSize &size,
+ const wxArrayString& choices,
+ long style, const wxValidator& validator,
+ const wxString &name )
+{
+ wxCArrayString chs(choices);
+
+ return Create( parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name );
+}
+
bool wxChoice::Create( wxWindow *parent, wxWindowID id,
const wxPoint &pos, const wxSize &size,
int n, const wxString choices[],
#if wxUSE_COMBOBOX
#include "wx/settings.h"
+#include "wx/arrstr.h"
#include "wx/intl.h"
#include "wx/textctrl.h" // for wxEVT_COMMAND_TEXT_UPDATED
EVT_CHAR(wxComboBox::OnChar)
END_EVENT_TABLE()
+bool wxComboBox::Create( wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos, const wxSize& size,
+ const wxArrayString& choices,
+ long style, const wxValidator& validator,
+ const wxString& name )
+{
+ wxCArrayString chs(choices);
+
+ return Create( parent, id, value, pos, size, chs.GetCount(),
+ chs.GetStrings(), style, validator, name );
+}
+
bool wxComboBox::Create( wxWindow *parent, wxWindowID id, const wxString& value,
const wxPoint& pos, const wxSize& size,
int n, const wxString choices[],
#endif // wxUSE_CHECKLISTBOX
}
+bool wxListBox::Create( wxWindow *parent, wxWindowID id,
+ const wxPoint &pos, const wxSize &size,
+ const wxArrayString& choices,
+ long style, const wxValidator& validator,
+ const wxString &name )
+{
+ wxCArrayString chs(choices);
+
+ return Create( parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name );
+}
+
bool wxListBox::Create( wxWindow *parent, wxWindowID id,
const wxPoint &pos, const wxSize &size,
int n, const wxString choices[],
m_lostFocus = FALSE;
}
+bool wxRadioBox::Create( wxWindow *parent, wxWindowID id,
+ const wxString& title,
+ const wxPoint &pos, const wxSize &size,
+ const wxArrayString& choices, int majorDim,
+ long style, const wxValidator& validator,
+ const wxString &name )
+{
+ wxCArrayString chs(choices);
+
+ return Create( parent, id, title, pos, size, chs.GetCount(),
+ chs.GetStrings(), majorDim, style, validator, name );
+}
+
bool wxRadioBox::Create( wxWindow *parent, wxWindowID id, const wxString& title,
const wxPoint &pos, const wxSize &size,
int n, const wxString choices[], int majorDim,
#if wxUSE_CHECKLISTBOX
#include "wx/checklst.h"
+#include "wx/arrstr.h"
#include "wx/mac/uma.h"
#include "Appearance.h"
{
}
+bool wxCheckListBox::Create(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint &pos,
+ const wxSize &size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString &name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
bool wxCheckListBox::Create(wxWindow *parent,
wxWindowID id,
const wxPoint &pos,
// DisposeMenu( m_macPopUpMenuHandle ) ;
}
+bool wxChoice::Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
bool wxChoice::Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos,
const wxSize& size,
}
+bool wxComboBox::Create(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs( choices );
+
+ return Create( parent, id, value, pos, size, chs.GetCount(),
+ chs.GetStrings(), style, validator, name );
+}
+
+
bool wxComboBox::Create(wxWindow *parent, wxWindowID id,
const wxString& value,
const wxPoint& pos,
static ListDefUPP macListDefUPP = NULL ;
+bool wxListBox::Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
bool wxListBox::Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos,
const wxSize& size,
//-------------------------------------------------------------------------------------
#include "wx/defs.h"
+#include "wx/arrstr.h"
#include "wx/radiobox.h"
#include "wx/radiobut.h"
//-------------------------------------------------------------------------------------
// Create the radiobox for two-step construction
+bool wxRadioBox::Create(wxWindow *parent, wxWindowID id, const wxString& label,
+ const wxPoint& pos, const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim, long style,
+ const wxValidator& val, const wxString& name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, label, pos, size, chs.GetCount(),
+ chs.GetStrings(), majorDim, style, val, name);
+}
+
bool wxRadioBox::Create(wxWindow *parent, wxWindowID id, const wxString& label,
const wxPoint& pos, const wxSize& size,
int n, const wxString choices[],
#if wxUSE_CHECKLISTBOX
#include "wx/checklst.h"
+#include "wx/arrstr.h"
#include "wx/mac/uma.h"
#include "Appearance.h"
{
}
+bool wxCheckListBox::Create(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint &pos,
+ const wxSize &size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString &name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
bool wxCheckListBox::Create(wxWindow *parent,
wxWindowID id,
const wxPoint &pos,
// DisposeMenu( m_macPopUpMenuHandle ) ;
}
+bool wxChoice::Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
bool wxChoice::Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos,
const wxSize& size,
}
+bool wxComboBox::Create(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs( choices );
+
+ return Create( parent, id, value, pos, size, chs.GetCount(),
+ chs.GetStrings(), style, validator, name );
+}
+
+
bool wxComboBox::Create(wxWindow *parent, wxWindowID id,
const wxString& value,
const wxPoint& pos,
static ListDefUPP macListDefUPP = NULL ;
+bool wxListBox::Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
bool wxListBox::Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos,
const wxSize& size,
//-------------------------------------------------------------------------------------
#include "wx/defs.h"
+#include "wx/arrstr.h"
#include "wx/radiobox.h"
#include "wx/radiobut.h"
//-------------------------------------------------------------------------------------
// Create the radiobox for two-step construction
+bool wxRadioBox::Create(wxWindow *parent, wxWindowID id, const wxString& label,
+ const wxPoint& pos, const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim, long style,
+ const wxValidator& val, const wxString& name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, label, pos, size, chs.GetCount(),
+ chs.GetStrings(), majorDim, style, val, name);
+}
+
bool wxRadioBox::Create(wxWindow *parent, wxWindowID id, const wxString& label,
const wxPoint& pos, const wxSize& size,
int n, const wxString choices[],
style, val, name);
}
+wxCheckListBox::wxCheckListBox(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos, const wxSize& size,
+ const wxArrayString& choices,
+ long style, const wxValidator& val,
+ const wxString& name)
+ : wxCheckListBoxBase()
+{
+ Create(parent, id, pos, size, choices,
+ style, val, name);
+}
+
bool wxCheckListBox::Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos,
const wxSize& size,
return retVal;
}
+bool wxCheckListBox::Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ // wxListBox::Create calls set, which adds the prefixes
+ bool retVal = wxListBox::Create(parent, id, pos, size, choices,
+ style, validator, name);
+ return retVal;
+}
+
// check items
// -----------
#include "wx/choice.h"
#include "wx/utils.h"
+#include "wx/arrstr.h"
#ifdef __VMS__
#pragma message disable nosimpint
return TRUE;
}
+bool wxChoice::Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
wxChoice::~wxChoice()
{
// For some reason destroying the menuWidget
#if wxUSE_COMBOBOX
#include "wx/combobox.h"
+#include "wx/arrstr.h"
#ifdef __VMS__
#pragma message disable nosimpint
return TRUE;
}
+bool wxComboBox::Create(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+ return Create(parent, id, value, pos, size, chs.GetCount(),
+ chs.GetStrings(), style, validator, name);
+}
+
wxComboBox::~wxComboBox()
{
DetachWidget((Widget) m_mainWidget); // Removes event handlers
#if wxUSE_COMBOBOX
#include "wx/combobox.h"
+#include "wx/arrstr.h"
#ifdef __VMS__
#pragma message disable nosimpint
return true;
}
+bool wxComboBox::Create(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+ return Create(parent, id, value, pos, size, chs.GetCount(),
+ chs.GetStrings(), style, validator, name);
+}
+
void wxComboBox::AdjustDropDownListSize()
{
int newListCount = -1, itemCount = GetCount();
#include "wx/dynarray.h"
#include "wx/log.h"
#include "wx/utils.h"
+#include "wx/arrstr.h"
#ifdef __VMS__
#pragma message disable nosimpint
return TRUE;
}
+bool wxListBox::Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
wxListBox::~wxListBox()
{
if( HasClientObjectData() )
m_font = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
}
+wxMenuBar::wxMenuBar(int n, wxMenu *menus[], const wxArrayString& titles)
+{
+ wxASSERT( size_t(n) == titles.GetCount() );
+
+ Init();
+
+ m_titles = titles;
+ for ( int i = 0; i < n; i++ )
+ m_menus.Append(menus[i]);
+}
+
wxMenuBar::wxMenuBar(int n, wxMenu *menus[], const wxString titles[])
{
Init();
#include "wx/radiobox.h"
#include "wx/utils.h"
+#include "wx/arrstr.h"
#ifdef __VMS__
#pragma message disable nosimpint
return TRUE;
}
+bool wxRadioBox::Create(wxWindow *parent, wxWindowID id, const wxString& title,
+ const wxPoint& pos, const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim, long style,
+ const wxValidator& val, const wxString& name)
+{
+ wxCArrayString chs(choices);
+ return Create(parent, id, title, pos, size, chs.GetCount(),
+ chs.GetStrings(), majorDim, style, val, name);
+}
wxRadioBox::~wxRadioBox()
{
Create(parent, id, pos, size, nStrings, choices, style, val, name);
}
+wxCheckListBox::wxCheckListBox(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos, const wxSize& size,
+ const wxArrayString& choices,
+ long style, const wxValidator& val,
+ const wxString& name)
+{
+ Create(parent, id, pos, size, choices, style, val, name);
+}
+
bool wxCheckListBox::Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos, const wxSize& size,
int n, const wxString choices[],
style | wxLB_OWNERDRAW, validator, name);
}
+bool wxCheckListBox::Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos, const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator, const wxString& name)
+{
+ return wxListBox::Create(parent, id, pos, size, choices,
+ style | wxLB_OWNERDRAW, validator, name);
+}
+
// misc overloaded methods
// -----------------------
return TRUE;
}
+bool wxChoice::Create(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
wxChoice::~wxChoice()
{
Free();
return TRUE;
}
+bool wxComboBox::Create(wxWindow *parent, wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+ return Create(parent, id, value, pos, size, chs.GetCount(),
+ chs.GetStrings(), style, validator, name);
+}
+
void wxComboBox::SetValue(const wxString& value)
{
if ( HasFlag(wxCB_READONLY) )
return TRUE;
}
+bool wxListBox::Create(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& wxVALIDATOR_PARAM(validator),
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
wxListBox::~wxListBox()
{
Free();
return TRUE;
}
+bool wxRadioBox::Create(wxWindow *parent,
+ wxWindowID id,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim,
+ long style,
+ const wxValidator& val,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+ return Create(parent, id, title, pos, size, chs.GetCount(),
+ chs.GetStrings(), majorDim, style, val, name);
+}
+
wxRadioBox::~wxRadioBox()
{
m_isBeingDeleted = TRUE;
);
} // end of wxCheckListBox::wxCheckListBox
+wxCheckListBox::wxCheckListBox (
+ wxWindow* pParent
+, wxWindowID vId
+, const wxPoint& rPos
+, const wxSize& rSize
+, const wxArrayString& asChoices
+, long lStyle
+, const wxValidator& rVal
+, const wxString& rsName
+)
+ : wxListBox()
+{
+ wxCArrayString chs(asChoices);
+ Create( pParent
+ ,vId
+ ,rPos
+ ,rSize
+ ,chs.GetCount()
+ ,chs.GetStrings()
+ ,lStyle | wxLB_OWNERDRAW
+ ,rVal
+ ,rsName
+ );
+} // end of wxCheckListBox::wxCheckListBox
+
void wxCheckListBox::Delete(
int N
)
IMPLEMENT_DYNAMIC_CLASS(wxChoice, wxControl)
+bool wxChoice::Create(
+ wxWindow* pParent
+, wxWindowID vId
+, const wxPoint& rPos
+, const wxSize& rSize
+, const wxArrayString& asChoices
+, long lStyle
+, const wxValidator& rValidator
+, const wxString& rsName
+)
+{
+ wxCArrayString chs(asChoices);
+
+ return Create(pParent, vId, rPos, rSize, chs.GetCount(), chs.GetStrings(),
+ lStyle, rValidator, rsName);
+}
+
bool wxChoice::Create(
wxWindow* pParent
, wxWindowID vId
return FALSE;
} // end of wxComboBox::OS2Command
+bool wxComboBox::Create(
+ wxWindow* pParent
+, wxWindowID vId
+, const wxString& rsValue
+, const wxPoint& rPos
+, const wxSize& rSize
+, const wxArrayString& asChoices
+, long lStyle
+, const wxValidator& rValidator
+, const wxString& rsName
+)
+{
+ wxCArrayString chs(asChoices);
+
+ return Create(pParent, vId, rsValue, rPos, rSize, chs.GetCount(),
+ chs.GetStrings(), lStyle, rValidator, rsName);
+}
+
bool wxComboBox::Create(
wxWindow* pParent
, wxWindowID vId
m_nSelected = 0;
} // end of wxListBox::wxListBox
+bool wxListBox::Create(
+ wxWindow* pParent
+, wxWindowID vId
+, const wxPoint& rPos
+, const wxSize& rSize
+, const wxArrayString& asChoices
+, long lStyle
+, const wxValidator& rValidator
+, const wxString& rsName
+)
+{
+ wxCArrayString chs(asChoices);
+
+ return Create(pParent, vId, rPos, rSize, chs.GetCount(), chs.GetStrings(),
+ lStyle, rValidator, rsName);
+}
+
bool wxListBox::Create(
wxWindow* pParent
, wxWindowID vId
return FALSE;
} // end of wxRadioBox::ContainsHWND
+bool wxRadioBox::Create(
+ wxWindow* pParent
+, wxWindowID vId
+, const wxString& rsTitle
+, const wxPoint& rPos
+, const wxSize& rSize
+, const wxArrayString& asChoices
+, int nMajorDim
+, long lStyle
+, const wxValidator& rVal
+, const wxString& rsName
+)
+{
+ wxCArrayString(asChoices);
+
+ return Create(pParent, vId, rsTitle, rPos, rSize, chs.GetCount(),
+ chs.GetStrings(), nMajorDim, lStyle, rVal, rsName);
+}
+
bool wxRadioBox::Create(
wxWindow* pParent
, wxWindowID vId
{
}
+wxCheckListBox::wxCheckListBox(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint &pos,
+ const wxSize &size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString &name)
+{
+ Init();
+
+ Create(parent, id, pos, size, choices, style, validator, name);
+}
+
+bool wxCheckListBox::Create(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint &pos,
+ const wxSize &size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString &name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
bool wxCheckListBox::Create(wxWindow *parent,
wxWindowID id,
const wxPoint &pos,
#ifndef WX_PRECOMP
#include "wx/choice.h"
+ #include "wx/arrstr.h"
#endif
IMPLEMENT_DYNAMIC_CLASS(wxChoice, wxControl)
EVT_COMBOBOX(-1, wxChoice::OnComboBox)
END_EVENT_TABLE()
+wxChoice::wxChoice(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ Create(parent, id, pos, size, choices, style, validator, name);
+}
+
+bool wxChoice::Create(wxWindow *parent, wxWindowID id,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
bool wxChoice::Create(wxWindow *parent, wxWindowID id,
const wxPoint& pos,
const wxSize& size,
m_lbox = (wxListBox *)NULL;
}
+wxComboBox::wxComboBox(wxWindow *parent,
+ wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ Init();
+
+ Create(parent, id, value, pos, size, choices, style, validator, name);
+}
+
+bool wxComboBox::Create(wxWindow *parent,
+ wxWindowID id,
+ const wxString& value,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, value, pos, size, chs.GetCount(),
+ chs.GetStrings(), style, validator, name);
+}
+
bool wxComboBox::Create(wxWindow *parent,
wxWindowID id,
const wxString& value,
m_showScrollbarY = FALSE;
}
+wxListBox::wxListBox(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint &pos,
+ const wxSize &size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString &name)
+{
+ Init();
+
+ Create(parent, id, pos, size, choices, style, validator, name);
+}
+
+bool wxListBox::Create(wxWindow *parent,
+ wxWindowID id,
+ const wxPoint &pos,
+ const wxSize &size,
+ const wxArrayString& choices,
+ long style,
+ const wxValidator& validator,
+ const wxString &name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, pos, size, chs.GetCount(), chs.GetStrings(),
+ style, validator, name);
+}
+
bool wxListBox::Create(wxWindow *parent,
wxWindowID id,
const wxPoint &pos,
#include "wx/radiobox.h"
#include "wx/radiobut.h"
#include "wx/validate.h"
+ #include "wx/arrstr.h"
#endif
#include "wx/tooltip.h"
m_majorDim = 0;
}
+wxRadioBox::wxRadioBox(wxWindow *parent, wxWindowID id, const wxString& title,
+ const wxPoint& pos, const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim, long style,
+ const wxValidator& val, const wxString& name)
+{
+ wxCArrayString chs(choices);
+
+ Init();
+
+ (void)Create(parent, id, title, pos, size, chs.GetCount(),
+ chs.GetStrings(), majorDim, style, val, name);
+}
+
+bool wxRadioBox::Create(wxWindow *parent,
+ wxWindowID id,
+ const wxString& title,
+ const wxPoint& pos,
+ const wxSize& size,
+ const wxArrayString& choices,
+ int majorDim,
+ long style,
+ const wxValidator& val,
+ const wxString& name)
+{
+ wxCArrayString chs(choices);
+
+ return Create(parent, id, title, pos, size, chs.GetCount(),
+ chs.GetStrings(), majorDim, style, val, name);
+}
+
bool wxRadioBox::Create(wxWindow *parent,
wxWindowID id,
const wxString& title,