Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
5.14.0
-
None
Description
If the QStyleHints::setFocusOnTouchRelease value is "true" and the combobox widget no focus, then it can't popup on mouse release.
See code:
QFontComboBox *box = new QFontComboBox(); box->setEditable(false); box->setFocusPolicy(Qt::NoFocus); box->show();
Copy form https://github.com/qt/qtbase/blob/dev/src/widgets/widgets/qcombobox.cpp#L3288 :
// Why "&& hasFocus()" in mouseReleaseEvent? void QComboBox::mouseReleaseEvent(QMouseEvent *e) { Q_D(QComboBox); d->updateArrow(QStyle::State_None); if (QGuiApplication::styleHints()->setFocusOnTouchRelease() && hasFocus()) d->showPopupFromMouseEvent(e); }
Is this a bug?