// Purpose: interface of wx[Multi|Single]ChoiceDialog
// Author: wxWidgets team
// RCS-ID: $Id$
-// Licence: wxWindows license
+// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
+/**
+ Default width of the choice dialog.
+*/
+#define wxCHOICE_WIDTH 150
+
+/**
+ Default height of the choice dialog.
+*/
+#define wxCHOICE_HEIGHT 200
+
+/**
+ Default style of the choice dialog.
+
+ @remarks wxRESIZE_BORDER is not used under WinCE.
+*/
+#define wxCHOICEDLG_STYLE (wxDEFAULT_DIALOG_STYLE | wxOK | wxCANCEL | wxCENTRE | wxRESIZE_BORDER)
+
+
/**
@class wxMultiChoiceDialog
/**
Returns array with indexes of selected items.
*/
- wxArrayInt GetSelection() const;
+ wxArrayInt GetSelections() const;
/**
Sets selected items from the array of selected items' indexes.
An array of strings, or a string list, containing the choices.
@param clientData
An array of client data to be associated with the items. See
- GetSelectionClientData().
+ GetSelectionData().
@param style
A dialog style (bitlist) containing flags chosen from standard
dialog styles and the ones listed below. The default value is
An array of strings, or a string list, containing the choices.
@param clientData
An array of client data to be associated with the items. See
- GetSelectionClientData().
+ GetSelectionData().
@param style
A dialog style (bitlist) containing flags chosen from standard
dialog styles and the ones listed below. The default value is
/**
Returns the client data associated with the selection.
+
+ @since 2.9.4
*/
- char* GetSelectionClientData() const;
+ void* GetSelectionData() const;
/**
Returns the selected string.
const wxString& caption,
const wxArrayString& aChoices,
wxWindow* parent = NULL,
- int x = -1,
- int y = -1,
+ int x = wxDefaultCoord,
+ int y = wxDefaultCoord,
bool centre = true,
- int width = 150,
- int height = 200,
+ int width = wxCHOICE_WIDTH,
+ int height = wxCHOICE_HEIGHT,
int initialSelection = 0);
int wxGetSingleChoiceIndex(const wxString& message,
int n,
const wxString& choices[],
wxWindow* parent = NULL,
- int x = -1,
- int y = -1,
+ int x = wxDefaultCoord,
+ int y = wxDefaultCoord,
bool centre = true,
- int width = 150,
- int height = 200,
+ int width = wxCHOICE_WIDTH,
+ int height = wxCHOICE_HEIGHT,
int initialSelection = 0);
const wxString& caption,
const wxArrayString& aChoices,
wxWindow* parent = NULL,
- int x = -1,
- int y = -1,
+ int x = wxDefaultCoord,
+ int y = wxDefaultCoord,
bool centre = true,
- int width = 150,
- int height = 200
+ int width = wxCHOICE_WIDTH,
+ int height = wxCHOICE_HEIGHT,
int initialSelection = 0);
wxString wxGetSingleChoice(const wxString& message,
const wxString& caption,
int n,
const wxString& choices[],
wxWindow* parent = NULL,
- int x = -1,
- int y = -1,
+ int x = wxDefaultCoord,
+ int y = wxDefaultCoord,
bool centre = true,
- int width = 150,
- int height = 200
+ int width = wxCHOICE_WIDTH,
+ int height = wxCHOICE_HEIGHT,
int initialSelection = 0);
const wxArrayString& aChoices,
const wxString& client_data[],
wxWindow* parent = NULL,
- int x = -1,
- int y = -1,
+ int x = wxDefaultCoord,
+ int y = wxDefaultCoord,
bool centre = true,
- int width = 150,
- int height = 200
+ int width = wxCHOICE_WIDTH,
+ int height = wxCHOICE_HEIGHT,
int initialSelection = 0);
wxString wxGetSingleChoiceData(const wxString& message,
const wxString& choices[],
const wxString& client_data[],
wxWindow* parent = NULL,
- int x = -1,
- int y = -1,
+ int x = wxDefaultCoord,
+ int y = wxDefaultCoord,
bool centre = true,
- int width = 150,
- int height = 200
+ int width = wxCHOICE_WIDTH,
+ int height = wxCHOICE_HEIGHT,
int initialSelection = 0);
void* wxGetSingleChoiceData(const wxString& message,
const wxString& caption,
const wxArrayString& aChoices,
wxWindow* parent = NULL,
- int x = -1,
- int y = -1,
+ int x = wxDefaultCoord,
+ int y = wxDefaultCoord,
bool centre = true,
- int width = 150,
- int height = 200);
+ int width = wxCHOICE_WIDTH,
+ int height = wxCHOICE_HEIGHT);
int wxGetSelectedChoices(wxArrayInt& selections,
const wxString& message,
int n,
const wxString& choices[],
wxWindow* parent = NULL,
- int x = -1,
- int y = -1,
+ int x = wxDefaultCoord,
+ int y = wxDefaultCoord,
bool centre = true,
- int width = 150,
- int height = 200);
+ int width = wxCHOICE_WIDTH,
+ int height = wxCHOICE_HEIGHT);
//@}