diff options
author | J-P Nurmi <jpnurmi@qt.io> | 2016-08-09 13:42:56 +0200 |
---|---|---|
committer | J-P Nurmi <jpnurmi@qt.io> | 2016-08-11 07:21:26 +0000 |
commit | 0bf6a3f4255c2e082db1f84de19034f05c48ce56 (patch) | |
tree | 249c285f319ceb85ffe6ac38f5cd7b3808c0009c /src/quicktemplates2/qquickcombobox_p.h | |
parent | 038a0c308a03977d3694e16b31c1cf7c7e1a5611 (diff) |
Add ComboBox::flat
[ChangeLog][ComboBox] Added a flat property that provides more suitable
looks for using ComboBox in a ToolBar.
Task-number: QTBUG-54935
Change-Id: Id458a078486aeac5d542a57f3ed247d63d25e95c
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Diffstat (limited to 'src/quicktemplates2/qquickcombobox_p.h')
-rw-r--r-- | src/quicktemplates2/qquickcombobox_p.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/quicktemplates2/qquickcombobox_p.h b/src/quicktemplates2/qquickcombobox_p.h index 26b7688e..3788d56a 100644 --- a/src/quicktemplates2/qquickcombobox_p.h +++ b/src/quicktemplates2/qquickcombobox_p.h @@ -62,6 +62,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickComboBox : public QQuickControl Q_PROPERTY(int count READ count NOTIFY countChanged FINAL) Q_PROPERTY(QVariant model READ model WRITE setModel NOTIFY modelChanged FINAL) Q_PROPERTY(QQmlInstanceModel *delegateModel READ delegateModel NOTIFY delegateModelChanged FINAL) + Q_PROPERTY(bool flat READ isFlat WRITE setFlat NOTIFY flatChanged FINAL REVISION 1) Q_PROPERTY(bool pressed READ isPressed WRITE setPressed NOTIFY pressedChanged FINAL) Q_PROPERTY(int highlightedIndex READ highlightedIndex NOTIFY highlightedIndexChanged FINAL) Q_PROPERTY(int currentIndex READ currentIndex WRITE setCurrentIndex NOTIFY currentIndexChanged FINAL) @@ -82,6 +83,9 @@ public: void setModel(const QVariant &model); QQmlInstanceModel *delegateModel() const; + bool isFlat() const; + void setFlat(bool flat); + bool isPressed() const; void setPressed(bool pressed); @@ -119,6 +123,7 @@ Q_SIGNALS: void countChanged(); void modelChanged(); void delegateModelChanged(); + Q_REVISION(1) void flatChanged(); void pressedChanged(); void highlightedIndexChanged(); void currentIndexChanged(); |