Added convenient wxCmdLineParser::AddLong{Option,Switch}() wrappers.
The new functions simply call Add{Option,Switch}() with an empty first argument but using them makes the code more readable. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69797 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -183,12 +183,25 @@ public:
|
||||
void AddSwitch(const wxString& name, const wxString& lng = wxEmptyString,
|
||||
const wxString& desc = wxEmptyString,
|
||||
int flags = 0);
|
||||
void AddLongSwitch(const wxString& lng,
|
||||
const wxString& desc = wxEmptyString,
|
||||
int flags = 0)
|
||||
{
|
||||
AddSwitch(wxString(), lng, desc, flags);
|
||||
}
|
||||
|
||||
// an option taking a value of the given type
|
||||
void AddOption(const wxString& name, const wxString& lng = wxEmptyString,
|
||||
const wxString& desc = wxEmptyString,
|
||||
wxCmdLineParamType type = wxCMD_LINE_VAL_STRING,
|
||||
int flags = 0);
|
||||
void AddLongOption(const wxString& lng,
|
||||
const wxString& desc = wxEmptyString,
|
||||
wxCmdLineParamType type = wxCMD_LINE_VAL_STRING,
|
||||
int flags = 0)
|
||||
{
|
||||
AddOption(wxString(), lng, desc, type, flags);
|
||||
}
|
||||
|
||||
// a parameter
|
||||
void AddParam(const wxString& desc = wxEmptyString,
|
||||
|
Reference in New Issue
Block a user