diff options
author | Dong Rui <dongrui@uniontech.com> | 2020-08-26 13:07:39 +0800 |
---|---|---|
committer | Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> | 2021-02-23 01:06:25 +0000 |
commit | 25d8f9da70401b4c9fb545eb488037f76ba770f7 (patch) | |
tree | b343f4a032f2f4f2d8d02339f98175429b4a878f /src/widgets | |
parent | e1cc406ea41b389862c8fc7f89be718f65363ff0 (diff) |
QLineEdit: Fix editingFinished() not being emitted when pressing the clear button
When pressing the clear button, the editingFinished() signal was not
received when focussing out.
Call _q_textEdited(QString()) when pressing the clear button.
Fixes: QTBUG-83295
Change-Id: Ie4bc6d9a2f27f89163c05c4c15175540c7631a30
Reviewed-by: Liang Qi <liang.qi@qt.io>
(cherry picked from commit c5904cb96aed3b171c543a2cf0bed8f8ac5f95c4)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'src/widgets')
-rw-r--r-- | src/widgets/widgets/qlineedit_p.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/widgets/widgets/qlineedit_p.cpp b/src/widgets/widgets/qlineedit_p.cpp index 1839941036..4143b848b5 100644 --- a/src/widgets/widgets/qlineedit_p.cpp +++ b/src/widgets/widgets/qlineedit_p.cpp @@ -479,7 +479,7 @@ void QLineEditPrivate::_q_clearButtonClicked() Q_Q(QLineEdit); if (!q->text().isEmpty()) { q->clear(); - emit q->textEdited(QString()); + _q_textEdited(QString()); } } |