diff options
author | Konstantin Ritt <ritt.ks@gmail.com> | 2011-10-18 16:44:54 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-02-21 21:05:25 +0100 |
commit | 432a75604819d9ed4143036c7cafa72106c768e0 (patch) | |
tree | 54ed7c217b3b4e22c7066e667f47534d4e025c34 /src/widgets | |
parent | c8160ea1dbb5c20856c9c385053f8e5611a9f4d6 (diff) |
replace 'const QChar &' with 'QChar ' where appropriate
as QChar is actually an ushort and there is no point in taking its
address.
Merge-request: 69
Change-Id: Idcc9d621e5627514ade006aa12a789a88929d48b
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Diffstat (limited to 'src/widgets')
-rw-r--r-- | src/widgets/widgets/qspinbox.cpp | 4 | ||||
-rw-r--r-- | src/widgets/widgets/qwidgetlinecontrol_p.h | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/widgets/widgets/qspinbox.cpp b/src/widgets/widgets/qspinbox.cpp index ee94368690..3038d8e30c 100644 --- a/src/widgets/widgets/qspinbox.cpp +++ b/src/widgets/widgets/qspinbox.cpp @@ -1157,8 +1157,8 @@ QVariant QDoubleSpinBoxPrivate::validateAndInterpret(QString &input, int &pos, } } } else { - const QChar &last = copy.at(len - 1); - const QChar &secondLast = copy.at(len - 2); + const QChar last = copy.at(len - 1); + const QChar secondLast = copy.at(len - 2); if ((last == locale.groupSeparator() || last.isSpace()) && (secondLast == locale.groupSeparator() || secondLast.isSpace())) { state = QValidator::Invalid; diff --git a/src/widgets/widgets/qwidgetlinecontrol_p.h b/src/widgets/widgets/qwidgetlinecontrol_p.h index 1d955363e6..a0191188a7 100644 --- a/src/widgets/widgets/qwidgetlinecontrol_p.h +++ b/src/widgets/widgets/qwidgetlinecontrol_p.h @@ -313,7 +313,7 @@ public: } QChar passwordCharacter() const { return m_passwordCharacter; } - void setPasswordCharacter(const QChar &character) { m_passwordCharacter = character; updateDisplayText(); } + void setPasswordCharacter(QChar character) { m_passwordCharacter = character; updateDisplayText(); } Qt::LayoutDirection layoutDirection() const { if (m_layoutDirection == Qt::LayoutDirectionAuto) { |