diff options
author | Marc Mutz <marc.mutz@kdab.com> | 2014-09-13 21:34:49 +0200 |
---|---|---|
committer | Marc Mutz <marc.mutz@kdab.com> | 2015-02-02 22:22:43 +0000 |
commit | 14511471df9b5596481b8fb1d81b559833d9afc8 (patch) | |
tree | 4a34174cdfa0fa394b814a210ccb0326956926a3 /src/widgets | |
parent | bf4c50ea336e929330ca6c15b8a3520cb55e82ca (diff) |
QCalendarWidget: use ctor-init-list (II)
Saves 32 bytes of text size.
Change-Id: I24e71f25f9a5a4c70e7948953e049dfb47c0e7d1
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
Diffstat (limited to 'src/widgets')
-rw-r--r-- | src/widgets/widgets/qcalendarwidget.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/widgets/widgets/qcalendarwidget.cpp b/src/widgets/widgets/qcalendarwidget.cpp index 3e2b982751..4309881fe2 100644 --- a/src/widgets/widgets/qcalendarwidget.cpp +++ b/src/widgets/widgets/qcalendarwidget.cpp @@ -489,9 +489,11 @@ private: }; QCalendarDateValidator::QCalendarDateValidator() - : m_currentToken(0), m_lastSectionMove(QCalendarDateSectionValidator::ThisSection) + : m_currentToken(Q_NULLPTR), + m_initialDate(QDate::currentDate()), + m_currentDate(m_initialDate), + m_lastSectionMove(QCalendarDateSectionValidator::ThisSection) { - m_initialDate = m_currentDate = QDate::currentDate(); m_yearValidator = new QCalendarYearValidator(); m_monthValidator = new QCalendarMonthValidator(); m_dayValidator = new QCalendarDayValidator(); |