diff options
author | Dong Rui <dongrui@uniontech.com> | 2021-03-09 10:41:31 +0800 |
---|---|---|
committer | Dong Rui <dongrui@uniontech.com> | 2021-03-09 13:20:53 +0800 |
commit | bac44956191b1b67139caec011878711635386ad (patch) | |
tree | 356b330fdd51542759ae98952784dd1a1bbc0917 /src/widgets/widgets/qcombobox.cpp | |
parent | bc1f61d010c8e71b1b649a888951f93da0ef838a (diff) |
Delete duplicate condition in QComboBox::setPlaceholderText
There is a duplicate condition judgment in QComboBox::setPlaceholderText, just delete it.
Change-Id: I570415c5930372866f290216a89260353d3992b7
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Diffstat (limited to 'src/widgets/widgets/qcombobox.cpp')
-rw-r--r-- | src/widgets/widgets/qcombobox.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/widgets/widgets/qcombobox.cpp b/src/widgets/widgets/qcombobox.cpp index 0194b7bf52..4f626f7428 100644 --- a/src/widgets/widgets/qcombobox.cpp +++ b/src/widgets/widgets/qcombobox.cpp @@ -1704,7 +1704,7 @@ void QComboBox::setPlaceholderText(const QString &placeholderText) d->placeholderText = placeholderText; if (currentIndex() == -1) { - if (d->placeholderText.isEmpty() && currentIndex() == -1) + if (d->placeholderText.isEmpty()) setCurrentIndex(0); else update(); |