mirror of https://github.com/qt/qtbase.git
QCalendarWidget: fix a bug when parsing date/time formats
Quoting was not reset after consuming the quoted character. This bug only manifests when a format contains two quoted characters. It's not possible to write an auto-test for this, since the format is always read from the locale. Change-Id: I39aff41f20f647c285c971b4d560f9e36d4b82fb Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
This commit is contained in:
parent
181980d4a7
commit
a2b453502c
|
@ -590,6 +590,7 @@ void QCalendarDateValidator::setFormat(const QString &format)
|
|||
const QChar nextChar = format.at(pos);
|
||||
if (quoting) {
|
||||
separator += nextChar;
|
||||
quoting = false;
|
||||
} else {
|
||||
SectionToken *token = 0;
|
||||
if (nextChar == QLatin1Char('d')) {
|
||||
|
|
Loading…
Reference in New Issue