summaryrefslogtreecommitdiffstats
path: root/src/widgets/widgets/qcombobox_p.h
diff options
context:
space:
mode:
authorRichard Moe Gustavsen <richard.gustavsen@theqtcompany.com>2015-03-25 11:23:39 +0100
committerRichard Moe Gustavsen <richard.gustavsen@theqtcompany.com>2015-04-04 08:47:06 +0000
commitd3277bdf02b701f78d21a5495a55fcaac08caf3d (patch)
treec407722534baad5c60e0323acd7bbb44c28b121c /src/widgets/widgets/qcombobox_p.h
parent9cb38baaf88b9f50eeed028ab66421c462f3124a (diff)
QComboBox: open popup on touch release if QStyleHints has setFocusOnTouchRelease()
If we give focus to the combobox on touch release, we need to await opening the popup until touch release as well. Otherwise we might end up showing a popup for an unfocused combobox. Especially on iOS, there is a strong coupling between focus object and popup menus, which means that we effectively require the combobox to gain focus before it can show the popup. Change-Id: Ifb7ba091bb39b77f325cdbf61e00ab3e8ff2e522 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Diffstat (limited to 'src/widgets/widgets/qcombobox_p.h')
-rw-r--r--src/widgets/widgets/qcombobox_p.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/widgets/widgets/qcombobox_p.h b/src/widgets/widgets/qcombobox_p.h
index 580054780f..3fdfdcc22f 100644
--- a/src/widgets/widgets/qcombobox_p.h
+++ b/src/widgets/widgets/qcombobox_p.h
@@ -253,6 +253,7 @@ private:
QElapsedTimer popupTimer;
friend class QComboBox;
+ friend class QComboBoxPrivate;
};
class Q_AUTOTEST_EXPORT QComboMenuDelegate : public QAbstractItemDelegate
@@ -372,6 +373,7 @@ public:
void modelChanged();
void updateViewContainerPaletteAndOpacity();
void updateFocusPolicy();
+ void showPopupFromMouseEvent(QMouseEvent *e);
#ifdef Q_OS_MAC
void cleanupNativePopup();