compilation fix for wchar_t-based builds after ParseISOXXX() additions
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@51524 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1128,21 +1128,21 @@ public:
|
|||||||
// provide compatibility overloads for them
|
// provide compatibility overloads for them
|
||||||
bool ParseISODate(const wxString& date)
|
bool ParseISODate(const wxString& date)
|
||||||
{
|
{
|
||||||
const wxStringCharType *p = ParseFormat(date, wxS("%Y-%m-%d"));
|
wxString::const_iterator end;
|
||||||
return p && !*p;
|
return ParseFormat(date, wxS("%Y-%m-%d"), &end) && end == date.end();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool ParseISOTime(const wxString& date)
|
bool ParseISOTime(const wxString& time)
|
||||||
{
|
{
|
||||||
const wxStringCharType *p = ParseFormat(date, wxS("%H:%M:%S"));
|
wxString::const_iterator end;
|
||||||
return p && !*p;
|
return ParseFormat(time, wxS("%H:%M:%S"), &end) && end == time.end();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool ParseISOCombined(const wxString& date, char sep = 'T')
|
bool ParseISOCombined(const wxString& datetime, char sep = 'T')
|
||||||
{
|
{
|
||||||
|
wxString::const_iterator end;
|
||||||
const wxString fmt = wxS("%Y-%m-%d") + wxString(sep) + wxS("%H:%M:%S");
|
const wxString fmt = wxS("%Y-%m-%d") + wxString(sep) + wxS("%H:%M:%S");
|
||||||
const wxStringCharType *p = ParseFormat(date, fmt.wx_str());
|
return ParseFormat(datetime, fmt, &end) && end == datetime.end();
|
||||||
return p && !*p;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// parse a string containing the date/time in "free" format, this
|
// parse a string containing the date/time in "free" format, this
|
||||||
|
Reference in New Issue
Block a user