summaryrefslogtreecommitdiffstats
path: root/src/gui/widgets/qlineedit_p.cpp
diff options
context:
space:
mode:
authorKim Motoyoshi Kalland <kim.kalland@nokia.com>2009-09-15 10:32:42 (GMT)
committerKim Motoyoshi Kalland <kim.kalland@nokia.com>2009-09-15 10:47:26 (GMT)
commit6a90f032d160f35058373fce16efd1b5d2190bf1 (patch)
tree9e95bf12c44eb2ab2a7d08b88d55aa4d4ca2c4e6 /src/gui/widgets/qlineedit_p.cpp
parentaf1cfbc945c7c01adea09d3d369699f4dd0daab9 (diff)
downloadQt-6a90f032d160f35058373fce16efd1b5d2190bf1.zip
Qt-6a90f032d160f35058373fce16efd1b5d2190bf1.tar.gz
Qt-6a90f032d160f35058373fce16efd1b5d2190bf1.tar.bz2
Fixed QLineEdit to pass the tst_QLineEdit::displayText() autotest.
Fetch the correct password character from the style. Reviewed-by: Olivier
Diffstat (limited to 'src/gui/widgets/qlineedit_p.cpp')
-rw-r--r--src/gui/widgets/qlineedit_p.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gui/widgets/qlineedit_p.cpp b/src/gui/widgets/qlineedit_p.cpp
index 4fe02a2..148da1b 100644
--- a/src/gui/widgets/qlineedit_p.cpp
+++ b/src/gui/widgets/qlineedit_p.cpp
@@ -159,7 +159,10 @@ void QLineEditPrivate::init(const QString& txt)
QObject::connect(control, SIGNAL(updateNeeded(const QRect &)),
q, SLOT(update()));
- control->setPasswordCharacter(q->style()->styleHint(QStyle::SH_LineEdit_PasswordCharacter));
+
+ QStyleOptionFrameV2 opt;
+ q->initStyleOption(&opt);
+ control->setPasswordCharacter(q->style()->styleHint(QStyle::SH_LineEdit_PasswordCharacter, &opt, q));
#ifndef QT_NO_CURSOR
q->setCursor(Qt::IBeamCursor);
#endif