diff options
Diffstat (limited to 'src/quicktemplates2')
22 files changed, 117 insertions, 69 deletions
diff --git a/src/quicktemplates2/qquickabstractbutton_p.h b/src/quicktemplates2/qquickabstractbutton_p.h index ecd297e7..ecce4299 100644 --- a/src/quicktemplates2/qquickabstractbutton_p.h +++ b/src/quicktemplates2/qquickabstractbutton_p.h @@ -66,6 +66,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickAbstractButton : public QQuickContr Q_PROPERTY(bool checkable READ isCheckable WRITE setCheckable NOTIFY checkableChanged FINAL) Q_PROPERTY(bool autoExclusive READ autoExclusive WRITE setAutoExclusive NOTIFY autoExclusiveChanged FINAL) Q_PROPERTY(QQuickItem *indicator READ indicator WRITE setIndicator NOTIFY indicatorChanged FINAL) + // 2.3 (Qt 5.10) Q_PROPERTY(QQuickIcon icon READ icon WRITE setIcon NOTIFY iconChanged FINAL REVISION 3) Q_PROPERTY(Display display READ display WRITE setDisplay NOTIFY displayChanged FINAL REVISION 3) Q_PROPERTY(QQuickAction *action READ action WRITE setAction NOTIFY actionChanged FINAL REVISION 3) @@ -99,6 +100,7 @@ public: QQuickItem *indicator() const; void setIndicator(QQuickItem *indicator); + // 2.3 (Qt 5.10) QQuickIcon icon() const; void setIcon(const QQuickIcon &icon); @@ -140,6 +142,7 @@ Q_SIGNALS: void indicatorChanged(); // 2.2 (Qt 5.9) Q_REVISION(2) void toggled(); + // 2.3 (Qt 5.10) Q_REVISION(3) void iconChanged(); Q_REVISION(3) void displayChanged(); Q_REVISION(3) void actionChanged(); diff --git a/src/quicktemplates2/qquickapplicationwindow.cpp b/src/quicktemplates2/qquickapplicationwindow.cpp index 222ceb52..d579afb2 100644 --- a/src/quicktemplates2/qquickapplicationwindow.cpp +++ b/src/quicktemplates2/qquickapplicationwindow.cpp @@ -349,6 +349,11 @@ QQuickApplicationWindow::~QQuickApplicationWindow() d_ptr.reset(); // QTBUG-52731 } +QQuickApplicationWindowAttached *QQuickApplicationWindow::qmlAttachedProperties(QObject *object) +{ + return new QQuickApplicationWindowAttached(object); +} + /*! \qmlproperty Item QtQuick.Controls::ApplicationWindow::background @@ -788,11 +793,6 @@ void QQuickApplicationWindow::setMenuBar(QQuickItem *menuBar) emit menuBarChanged(); } -QQuickApplicationWindowAttached *QQuickApplicationWindow::qmlAttachedProperties(QObject *object) -{ - return new QQuickApplicationWindowAttached(object); -} - bool QQuickApplicationWindow::isComponentComplete() const { Q_D(const QQuickApplicationWindow); diff --git a/src/quicktemplates2/qquickapplicationwindow_p.h b/src/quicktemplates2/qquickapplicationwindow_p.h index 97fe3d0c..4e24009f 100644 --- a/src/quicktemplates2/qquickapplicationwindow_p.h +++ b/src/quicktemplates2/qquickapplicationwindow_p.h @@ -73,6 +73,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickApplicationWindow : public QQuickWi Q_PROPERTY(QQuickOverlay *overlay READ overlay CONSTANT FINAL) Q_PROPERTY(QFont font READ font WRITE setFont RESET resetFont NOTIFY fontChanged FINAL) Q_PROPERTY(QLocale locale READ locale WRITE setLocale RESET resetLocale NOTIFY localeChanged FINAL) + // 2.3 (Qt 5.10) Q_PROPERTY(QPalette palette READ palette WRITE setPalette RESET resetPalette NOTIFY paletteChanged FINAL REVISION 3) Q_PROPERTY(QQuickItem *menuBar READ menuBar WRITE setMenuBar NOTIFY menuBarChanged FINAL REVISION 3) Q_CLASSINFO("DefaultProperty", "contentData") @@ -81,6 +82,8 @@ public: explicit QQuickApplicationWindow(QWindow *parent = nullptr); ~QQuickApplicationWindow(); + static QQuickApplicationWindowAttached *qmlAttachedProperties(QObject *object); + QQuickItem *background() const; void setBackground(QQuickItem *background); @@ -105,6 +108,7 @@ public: void setLocale(const QLocale &locale); void resetLocale(); + // 2.3 (Qt 5.10) QPalette palette() const; void setPalette(const QPalette &palette); void resetPalette(); @@ -112,8 +116,6 @@ public: QQuickItem *menuBar() const; void setMenuBar(QQuickItem *menuBar); - static QQuickApplicationWindowAttached *qmlAttachedProperties(QObject *object); - Q_SIGNALS: void backgroundChanged(); void activeFocusControlChanged(); @@ -166,6 +168,7 @@ Q_SIGNALS: void headerChanged(); void footerChanged(); void overlayChanged(); + // 2.3 (Qt 5.10) /*Q_REVISION(3)*/ void menuBarChanged(); private: diff --git a/src/quicktemplates2/qquickbuttongroup_p.h b/src/quicktemplates2/qquickbuttongroup_p.h index 51712b03..53f8be8c 100644 --- a/src/quicktemplates2/qquickbuttongroup_p.h +++ b/src/quicktemplates2/qquickbuttongroup_p.h @@ -64,6 +64,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickButtonGroup : public QObject Q_OBJECT Q_PROPERTY(QQuickAbstractButton *checkedButton READ checkedButton WRITE setCheckedButton NOTIFY checkedButtonChanged FINAL) Q_PROPERTY(QQmlListProperty<QQuickAbstractButton> buttons READ buttons NOTIFY buttonsChanged FINAL) + // 2.3 (Qt 5.10) Q_PROPERTY(bool exclusive READ isExclusive WRITE setExclusive NOTIFY exclusiveChanged FINAL REVISION 3) public: @@ -89,6 +90,7 @@ Q_SIGNALS: void buttonsChanged(); // 2.1 (Qt 5.8) Q_REVISION(1) void clicked(QQuickAbstractButton *button); + // 2.3 (Qt 5.10) Q_REVISION(3) void exclusiveChanged(); private: diff --git a/src/quicktemplates2/qquickcontainer_p.h b/src/quicktemplates2/qquickcontainer_p.h index 8cea0755..030497cf 100644 --- a/src/quicktemplates2/qquickcontainer_p.h +++ b/src/quicktemplates2/qquickcontainer_p.h @@ -77,6 +77,7 @@ public: Q_INVOKABLE void moveItem(int from, int to); Q_INVOKABLE void removeItem(const QVariant &item); // ### Qt 6: remove void removeItem(QQuickItem *item); // ### Qt 6: Q_INVOKABLE + // 2.3 (Qt 5.10) Q_REVISION(3) Q_INVOKABLE QQuickItem *takeItem(int index); QVariant contentModel() const; diff --git a/src/quicktemplates2/qquickcontrol_p.h b/src/quicktemplates2/qquickcontrol_p.h index eaf00ced..7dd1deb3 100644 --- a/src/quicktemplates2/qquickcontrol_p.h +++ b/src/quicktemplates2/qquickcontrol_p.h @@ -79,6 +79,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickControl : public QQuickItem Q_PROPERTY(bool wheelEnabled READ isWheelEnabled WRITE setWheelEnabled NOTIFY wheelEnabledChanged FINAL) Q_PROPERTY(QQuickItem *background READ background WRITE setBackground NOTIFY backgroundChanged FINAL) Q_PROPERTY(QQuickItem *contentItem READ contentItem WRITE setContentItem NOTIFY contentItemChanged FINAL) + // 2.3 (Qt 5.10) Q_PROPERTY(QPalette palette READ palette WRITE setPalette RESET resetPalette NOTIFY paletteChanged FINAL REVISION 3) public: @@ -145,6 +146,7 @@ public: QQuickItem *contentItem() const; void setContentItem(QQuickItem *item); + // 2.3 (Qt 5.10) QPalette palette() const; void setPalette(const QPalette &palette); void resetPalette(); @@ -169,6 +171,7 @@ Q_SIGNALS: void wheelEnabledChanged(); void backgroundChanged(); void contentItemChanged(); + // 2.3 (Qt 5.10) Q_REVISION(3) void paletteChanged(); protected: diff --git a/src/quicktemplates2/qquickdialog_p.h b/src/quicktemplates2/qquickdialog_p.h index 8032cf83..d22685b6 100644 --- a/src/quicktemplates2/qquickdialog_p.h +++ b/src/quicktemplates2/qquickdialog_p.h @@ -63,6 +63,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickDialog : public QQuickPopup Q_PROPERTY(QQuickItem *header READ header WRITE setHeader NOTIFY headerChanged FINAL) Q_PROPERTY(QQuickItem *footer READ footer WRITE setFooter NOTIFY footerChanged FINAL) Q_PROPERTY(QPlatformDialogHelper::StandardButtons standardButtons READ standardButtons WRITE setStandardButtons NOTIFY standardButtonsChanged FINAL) + // 2.3 (Qt 5.10) Q_PROPERTY(int result READ result WRITE setResult NOTIFY resultChanged FINAL REVISION 3) Q_FLAGS(QPlatformDialogHelper::StandardButtons) @@ -82,6 +83,7 @@ public: void setStandardButtons(QPlatformDialogHelper::StandardButtons buttons); Q_REVISION(3) Q_INVOKABLE QQuickAbstractButton *standardButton(QPlatformDialogHelper::StandardButton button) const; + // 2.3 (Qt 5.10) enum StandardCode { Rejected, Accepted }; Q_ENUM(StandardCode) @@ -96,15 +98,15 @@ public Q_SLOTS: Q_SIGNALS: void accepted(); void rejected(); - Q_REVISION(3) void applied(); - Q_REVISION(3) void reset(); - Q_REVISION(3) void discarded(); - Q_REVISION(3) void helpRequested(); - void titleChanged(); void headerChanged(); void footerChanged(); void standardButtonsChanged(); + // 2.3 (Qt 5.10) + Q_REVISION(3) void applied(); + Q_REVISION(3) void reset(); + Q_REVISION(3) void discarded(); + Q_REVISION(3) void helpRequested(); Q_REVISION(3) void resultChanged(); protected: diff --git a/src/quicktemplates2/qquickdialogbuttonbox_p.h b/src/quicktemplates2/qquickdialogbuttonbox_p.h index 5d6e568e..1e3cdeef 100644 --- a/src/quicktemplates2/qquickdialogbuttonbox_p.h +++ b/src/quicktemplates2/qquickdialogbuttonbox_p.h @@ -98,15 +98,15 @@ Q_SIGNALS: void accepted(); void rejected(); void helpRequested(); - Q_REVISION(3) void applied(); - Q_REVISION(3) void reset(); - Q_REVISION(3) void discarded(); void clicked(QQuickAbstractButton *button); - void positionChanged(); void alignmentChanged(); void standardButtonsChanged(); void delegateChanged(); + // 2.3 (Qt 5.10) + Q_REVISION(3) void applied(); + Q_REVISION(3) void reset(); + Q_REVISION(3) void discarded(); protected: void updatePolish() override; diff --git a/src/quicktemplates2/qquicklabel_p.h b/src/quicktemplates2/qquicklabel_p.h index a102c89a..937c57eb 100644 --- a/src/quicktemplates2/qquicklabel_p.h +++ b/src/quicktemplates2/qquicklabel_p.h @@ -61,6 +61,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickLabel : public QQuickText Q_OBJECT Q_PROPERTY(QFont font READ font WRITE setFont NOTIFY fontChanged) // override Q_PROPERTY(QQuickItem *background READ background WRITE setBackground NOTIFY backgroundChanged FINAL) + // 2.3 (Qt 5.10) Q_PROPERTY(QPalette palette READ palette WRITE setPalette RESET resetPalette NOTIFY paletteChanged FINAL REVISION 3) public: @@ -72,6 +73,7 @@ public: QQuickItem *background() const; void setBackground(QQuickItem *background); + // 2.3 (Qt 5.10) QPalette palette() const; void setPalette(const QPalette &palette); void resetPalette(); @@ -79,6 +81,7 @@ public: Q_SIGNALS: void fontChanged(); void backgroundChanged(); + // 2.3 (Qt 5.10) Q_REVISION(3) void paletteChanged(); protected: diff --git a/src/quicktemplates2/qquickmenu.cpp b/src/quicktemplates2/qquickmenu.cpp index 9b196930..7ebeb344 100644 --- a/src/quicktemplates2/qquickmenu.cpp +++ b/src/quicktemplates2/qquickmenu.cpp @@ -661,19 +661,6 @@ QQuickMenu::QQuickMenu(QObject *parent) } /*! - \since QtQuick.Controls 2.3 (Qt 5.10) - \qmlproperty int QtQuick.Controls::Menu::count - \readonly - - This property holds the number of items. -*/ -int QQuickMenu::count() const -{ - Q_D(const QQuickMenu); - return d->contentModel->count(); -} - -/*! \qmlmethod Item QtQuick.Controls::Menu::itemAt(int index) Returns the item at \a index, or \c null if it does not exist. @@ -1181,6 +1168,19 @@ void QQuickMenu::setCurrentIndex(int index) d->setCurrentIndex(index, Qt::OtherFocusReason); } +/*! + \since QtQuick.Controls 2.3 (Qt 5.10) + \qmlproperty int QtQuick.Controls::Menu::count + \readonly + + This property holds the number of items. +*/ +int QQuickMenu::count() const +{ + Q_D(const QQuickMenu); + return d->contentModel->count(); +} + void QQuickMenu::popup(QQuickItem *menuItem) { Q_D(QQuickMenu); diff --git a/src/quicktemplates2/qquickmenu_p.h b/src/quicktemplates2/qquickmenu_p.h index 80c4c055..01b970f8 100644 --- a/src/quicktemplates2/qquickmenu_p.h +++ b/src/quicktemplates2/qquickmenu_p.h @@ -63,10 +63,11 @@ class QQuickMenuPrivate; class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickMenu : public QQuickPopup { Q_OBJECT - Q_PROPERTY(int count READ count NOTIFY countChanged FINAL REVISION 3) Q_PROPERTY(QVariant contentModel READ contentModel CONSTANT FINAL) Q_PROPERTY(QQmlListProperty<QObject> contentData READ contentData FINAL) Q_PROPERTY(QString title READ title WRITE setTitle NOTIFY titleChanged FINAL) + // 2.3 (Qt 5.10) + Q_PROPERTY(int count READ count NOTIFY countChanged FINAL REVISION 3) Q_PROPERTY(bool cascade READ cascade WRITE setCascade RESET resetCascade NOTIFY cascadeChanged FINAL REVISION 3) Q_PROPERTY(qreal overlap READ overlap WRITE setOverlap NOTIFY overlapChanged FINAL REVISION 3) Q_PROPERTY(QQmlComponent *delegate READ delegate WRITE setDelegate NOTIFY delegateChanged FINAL REVISION 3) @@ -76,26 +77,12 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickMenu : public QQuickPopup public: explicit QQuickMenu(QObject *parent = nullptr); - int count() const; Q_INVOKABLE QQuickItem *itemAt(int index) const; Q_INVOKABLE void addItem(QQuickItem *item); Q_INVOKABLE void insertItem(int index, QQuickItem *item); Q_INVOKABLE void moveItem(int from, int to); Q_INVOKABLE void removeItem(const QVariant &item); // ### Qt 6: remove void removeItem(QQuickItem *item); // ### Qt 6: Q_INVOKABLE - Q_REVISION(3) Q_INVOKABLE QQuickItem *takeItem(int index); - - Q_REVISION(3) Q_INVOKABLE QQuickMenu *menuAt(int index) const; - Q_REVISION(3) Q_INVOKABLE void addMenu(QQuickMenu *menu); - Q_REVISION(3) Q_INVOKABLE void insertMenu(int index, QQuickMenu *menu); - Q_REVISION(3) Q_INVOKABLE void removeMenu(QQuickMenu *menu); - Q_REVISION(3) Q_INVOKABLE QQuickMenu *takeMenu(int index); - - Q_REVISION(3) Q_INVOKABLE QQuickAction *actionAt(int index) const; - Q_REVISION(3) Q_INVOKABLE void addAction(QQuickAction *action); - Q_REVISION(3) Q_INVOKABLE void insertAction(int index, QQuickAction *action); - Q_REVISION(3) Q_INVOKABLE void removeAction(QQuickAction *action); - Q_REVISION(3) Q_INVOKABLE QQuickAction *takeAction(int index); QVariant contentModel() const; QQmlListProperty<QObject> contentData(); @@ -116,6 +103,22 @@ public: int currentIndex() const; void setCurrentIndex(int index); + // 2.3 (Qt 5.10) + int count() const; + Q_REVISION(3) Q_INVOKABLE QQuickItem *takeItem(int index); + + Q_REVISION(3) Q_INVOKABLE QQuickMenu *menuAt(int index) const; + Q_REVISION(3) Q_INVOKABLE void addMenu(QQuickMenu *menu); + Q_REVISION(3) Q_INVOKABLE void insertMenu(int index, QQuickMenu *menu); + Q_REVISION(3) Q_INVOKABLE void removeMenu(QQuickMenu *menu); + Q_REVISION(3) Q_INVOKABLE QQuickMenu *takeMenu(int index); + + Q_REVISION(3) Q_INVOKABLE QQuickAction *actionAt(int index) const; + Q_REVISION(3) Q_INVOKABLE void addAction(QQuickAction *action); + Q_REVISION(3) Q_INVOKABLE void insertAction(int index, QQuickAction *action); + Q_REVISION(3) Q_INVOKABLE void removeAction(QQuickAction *action); + Q_REVISION(3) Q_INVOKABLE QQuickAction *takeAction(int index); + void popup(QQuickItem *menuItem = nullptr); void popup(const QPointF &pos, QQuickItem *menuItem = nullptr); @@ -129,8 +132,9 @@ protected: void keyPressEvent(QKeyEvent *event) override; Q_SIGNALS: - Q_REVISION(3) void countChanged(); void titleChanged(const QString &title); + // 2.3 (Qt 5.10) + Q_REVISION(3) void countChanged(); Q_REVISION(3) void cascadeChanged(bool cascade); Q_REVISION(3) void overlapChanged(); Q_REVISION(3) void delegateChanged(); diff --git a/src/quicktemplates2/qquickmenuitem_p.h b/src/quicktemplates2/qquickmenuitem_p.h index 7c469b6a..8af3cbd1 100644 --- a/src/quicktemplates2/qquickmenuitem_p.h +++ b/src/quicktemplates2/qquickmenuitem_p.h @@ -59,6 +59,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickMenuItem : public QQuickAbstractBut { Q_OBJECT Q_PROPERTY(bool highlighted READ isHighlighted WRITE setHighlighted NOTIFY highlightedChanged FINAL) + // 2.3 (Qt 5.10) Q_PROPERTY(QQuickItem *arrow READ arrow WRITE setArrow NOTIFY arrowChanged FINAL REVISION 3) Q_PROPERTY(QQuickMenu *menu READ menu NOTIFY menuChanged FINAL REVISION 3) Q_PROPERTY(QQuickMenu *subMenu READ subMenu NOTIFY subMenuChanged FINAL REVISION 3) @@ -69,6 +70,7 @@ public: bool isHighlighted() const; void setHighlighted(bool highlighted); + // 2.3 (Qt 5.10) QQuickItem *arrow() const; void setArrow(QQuickItem *arrow); @@ -78,6 +80,7 @@ public: Q_SIGNALS: void triggered(); void highlightedChanged(); + // 2.3 (Qt 5.10) Q_REVISION(3) void arrowChanged(); Q_REVISION(3) void menuChanged(); Q_REVISION(3) void subMenuChanged(); diff --git a/src/quicktemplates2/qquickpopup_p.h b/src/quicktemplates2/qquickpopup_p.h index 9dc4115e..ada4b649 100644 --- a/src/quicktemplates2/qquickpopup_p.h +++ b/src/quicktemplates2/qquickpopup_p.h @@ -96,9 +96,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickPopup : public QObject, public QQml Q_PROPERTY(qreal rightPadding READ rightPadding WRITE setRightPadding RESET resetRightPadding NOTIFY rightPaddingChanged FINAL) Q_PROPERTY(qreal bottomPadding READ bottomPadding WRITE setBottomPadding RESET resetBottomPadding NOTIFY bottomPaddingChanged FINAL) Q_PROPERTY(QLocale locale READ locale WRITE setLocale RESET resetLocale NOTIFY localeChanged FINAL) - Q_PROPERTY(bool mirrored READ isMirrored NOTIFY mirroredChanged FINAL REVISION 3) Q_PROPERTY(QFont font READ font WRITE setFont RESET resetFont NOTIFY fontChanged FINAL) - Q_PROPERTY(QPalette palette READ palette WRITE setPalette RESET resetPalette NOTIFY paletteChanged FINAL REVISION 3) Q_PROPERTY(QQuickItem *parent READ parentItem WRITE setParentItem RESET resetParentItem NOTIFY parentChanged FINAL) Q_PROPERTY(QQuickItem *background READ background WRITE setBackground NOTIFY backgroundChanged FINAL) Q_PROPERTY(QQuickItem *contentItem READ contentItem WRITE setContentItem NOTIFY contentItemChanged FINAL) @@ -110,8 +108,6 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickPopup : public QObject, public QQml Q_PROPERTY(bool modal READ isModal WRITE setModal NOTIFY modalChanged FINAL) Q_PROPERTY(bool dim READ dim WRITE setDim RESET resetDim NOTIFY dimChanged FINAL) Q_PROPERTY(bool visible READ isVisible WRITE setVisible NOTIFY visibleChanged FINAL) - Q_PROPERTY(bool enabled READ isEnabled WRITE setEnabled NOTIFY enabledChanged FINAL REVISION 3) - Q_PROPERTY(bool opened READ isOpened NOTIFY openedChanged FINAL REVISION 3) Q_PROPERTY(qreal opacity READ opacity WRITE setOpacity NOTIFY opacityChanged FINAL) Q_PROPERTY(qreal scale READ scale WRITE setScale NOTIFY scaleChanged FINAL) Q_PROPERTY(ClosePolicy closePolicy READ closePolicy WRITE setClosePolicy RESET resetClosePolicy NOTIFY closePolicyChanged FINAL) @@ -120,6 +116,11 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickPopup : public QObject, public QQml Q_PROPERTY(QQuickTransition *exit READ exit WRITE setExit NOTIFY exitChanged FINAL) // 2.1 (Qt 5.8) Q_PROPERTY(qreal spacing READ spacing WRITE setSpacing RESET resetSpacing NOTIFY spacingChanged FINAL REVISION 1) + // 2.3 (Qt 5.10) + Q_PROPERTY(bool opened READ isOpened NOTIFY openedChanged FINAL REVISION 3) + Q_PROPERTY(bool mirrored READ isMirrored NOTIFY mirroredChanged FINAL REVISION 3) + Q_PROPERTY(bool enabled READ isEnabled WRITE setEnabled NOTIFY enabledChanged FINAL REVISION 3) + Q_PROPERTY(QPalette palette READ palette WRITE setPalette RESET resetPalette NOTIFY paletteChanged FINAL REVISION 3) Q_CLASSINFO("DefaultProperty", "contentData") public: @@ -205,16 +206,10 @@ public: void setLocale(const QLocale &locale); void resetLocale(); - bool isMirrored() const; - QFont font() const; void setFont(const QFont &font); void resetFont(); - QPalette palette() const; - void setPalette(const QPalette &palette); - void resetPalette(); - QQuickWindow *window() const; QQuickItem *popupItem() const; @@ -249,11 +244,6 @@ public: bool isVisible() const; virtual void setVisible(bool visible); - bool isEnabled() const; - void setEnabled(bool enabled); - - bool isOpened() const; - qreal opacity() const; void setOpacity(qreal opacity); @@ -302,6 +292,17 @@ public: void setSpacing(qreal spacing); void resetSpacing(); + // 2.3 (Qt 5.10) + bool isOpened() const; + bool isMirrored() const; + + bool isEnabled() const; + void setEnabled(bool enabled); + + QPalette palette() const; + void setPalette(const QPalette &palette); + void resetPalette(); + public Q_SLOTS: void open(); void close(); @@ -334,8 +335,6 @@ Q_SIGNALS: void bottomPaddingChanged(); void fontChanged(); void localeChanged(); - Q_REVISION(3) void mirroredChanged(); - Q_REVISION(3) void paletteChanged(); void parentChanged(); void backgroundChanged(); void contentItemChanged(); @@ -346,8 +345,6 @@ Q_SIGNALS: void modalChanged(); void dimChanged(); void visibleChanged(); - Q_REVISION(3) void enabledChanged(); - Q_REVISION(3) void openedChanged(); void opacityChanged(); void scaleChanged(); void closePolicyChanged(); @@ -356,6 +353,11 @@ Q_SIGNALS: void windowChanged(QQuickWindow *window); // 2.1 (Qt 5.8) Q_REVISION(1) void spacingChanged(); + // 2.3 (Qt 5.10) + Q_REVISION(3) void openedChanged(); + Q_REVISION(3) void mirroredChanged(); + Q_REVISION(3) void enabledChanged(); + Q_REVISION(3) void paletteChanged(); protected: QQuickPopup(QQuickPopupPrivate &dd, QObject *parent); diff --git a/src/quicktemplates2/qquickrangeslider_p.h b/src/quicktemplates2/qquickrangeslider_p.h index 03c0c663..ef6e5677 100644 --- a/src/quicktemplates2/qquickrangeslider_p.h +++ b/src/quicktemplates2/qquickrangeslider_p.h @@ -68,6 +68,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickRangeSlider : public QQuickControl // 2.2 (Qt 5.9) Q_PROPERTY(bool live READ live WRITE setLive NOTIFY liveChanged FINAL REVISION 2) Q_PROPERTY(bool horizontal READ isHorizontal NOTIFY orientationChanged FINAL REVISION 3) + // 2.3 (Qt 5.10) Q_PROPERTY(bool vertical READ isVertical NOTIFY orientationChanged FINAL REVISION 3) public: @@ -104,6 +105,7 @@ public: bool live() const; void setLive(bool live); + // 2.3 (Qt 5.10) bool isHorizontal() const; bool isVertical() const; diff --git a/src/quicktemplates2/qquickscrollbar_p.h b/src/quicktemplates2/qquickscrollbar_p.h index b4a92d0a..6dda6f2e 100644 --- a/src/quicktemplates2/qquickscrollbar_p.h +++ b/src/quicktemplates2/qquickscrollbar_p.h @@ -68,6 +68,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickScrollBar : public QQuickControl Q_PROPERTY(SnapMode snapMode READ snapMode WRITE setSnapMode NOTIFY snapModeChanged FINAL REVISION 2) Q_PROPERTY(bool interactive READ isInteractive WRITE setInteractive RESET resetInteractive NOTIFY interactiveChanged FINAL REVISION 2) Q_PROPERTY(Policy policy READ policy WRITE setPolicy NOTIFY policyChanged FINAL REVISION 2) + // 2.3 (Qt 5.10) Q_PROPERTY(bool horizontal READ isHorizontal NOTIFY orientationChanged FINAL REVISION 3) Q_PROPERTY(bool vertical READ isVertical NOTIFY orientationChanged FINAL REVISION 3) @@ -116,6 +117,7 @@ public: Policy policy() const; void setPolicy(Policy policy); + // 2.3 (Qt 5.10) bool isHorizontal() const; bool isVertical() const; diff --git a/src/quicktemplates2/qquickscrollindicator_p.h b/src/quicktemplates2/qquickscrollindicator_p.h index c1065a3f..d679cf74 100644 --- a/src/quicktemplates2/qquickscrollindicator_p.h +++ b/src/quicktemplates2/qquickscrollindicator_p.h @@ -63,6 +63,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickScrollIndicator : public QQuickCont Q_PROPERTY(qreal position READ position WRITE setPosition NOTIFY positionChanged FINAL) Q_PROPERTY(bool active READ isActive WRITE setActive NOTIFY activeChanged FINAL) Q_PROPERTY(Qt::Orientation orientation READ orientation WRITE setOrientation NOTIFY orientationChanged FINAL) + // 2.3 (Qt 5.10) Q_PROPERTY(bool horizontal READ isHorizontal NOTIFY orientationChanged FINAL REVISION 3) Q_PROPERTY(bool vertical READ isVertical NOTIFY orientationChanged FINAL REVISION 3) @@ -80,6 +81,7 @@ public: Qt::Orientation orientation() const; void setOrientation(Qt::Orientation orientation); + // 2.3 (Qt 5.10) bool isHorizontal() const; bool isVertical() const; diff --git a/src/quicktemplates2/qquickslider_p.h b/src/quicktemplates2/qquickslider_p.h index 91b26b75..b2f4897c 100644 --- a/src/quicktemplates2/qquickslider_p.h +++ b/src/quicktemplates2/qquickslider_p.h @@ -65,11 +65,12 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickSlider : public QQuickControl Q_PROPERTY(qreal stepSize READ stepSize WRITE setStepSize NOTIFY stepSizeChanged FINAL) Q_PROPERTY(SnapMode snapMode READ snapMode WRITE setSnapMode NOTIFY snapModeChanged FINAL) Q_PROPERTY(bool pressed READ isPressed WRITE setPressed NOTIFY pressedChanged FINAL) - Q_PROPERTY(bool horizontal READ isHorizontal NOTIFY orientationChanged FINAL REVISION 3) - Q_PROPERTY(bool vertical READ isVertical NOTIFY orientationChanged FINAL REVISION 3) Q_PROPERTY(Qt::Orientation orientation READ orientation WRITE setOrientation NOTIFY orientationChanged FINAL) Q_PROPERTY(QQuickItem *handle READ handle WRITE setHandle NOTIFY handleChanged FINAL) Q_PROPERTY(bool live READ live WRITE setLive NOTIFY liveChanged FINAL REVISION 2) + // 2.3 (Qt 5.10) + Q_PROPERTY(bool horizontal READ isHorizontal NOTIFY orientationChanged FINAL REVISION 3) + Q_PROPERTY(bool vertical READ isVertical NOTIFY orientationChanged FINAL REVISION 3) public: explicit QQuickSlider(QQuickItem *parent = nullptr); @@ -102,9 +103,6 @@ public: bool isPressed() const; void setPressed(bool pressed); - bool isHorizontal() const; - bool isVertical() const; - Qt::Orientation orientation() const; void setOrientation(Qt::Orientation orientation); @@ -118,6 +116,10 @@ public: bool live() const; void setLive(bool live); + // 2.3 (Qt 5.10) + bool isHorizontal() const; + bool isVertical() const; + public Q_SLOTS: void increase(); void decrease(); diff --git a/src/quicktemplates2/qquickspinbox_p.h b/src/quicktemplates2/qquickspinbox_p.h index 26c1dd40..6485c053 100644 --- a/src/quicktemplates2/qquickspinbox_p.h +++ b/src/quicktemplates2/qquickspinbox_p.h @@ -74,6 +74,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickSpinBox : public QQuickControl // 2.2 (Qt 5.9) Q_PROPERTY(Qt::InputMethodHints inputMethodHints READ inputMethodHints WRITE setInputMethodHints NOTIFY inputMethodHintsChanged FINAL REVISION 2) Q_PROPERTY(bool inputMethodComposing READ isInputMethodComposing NOTIFY inputMethodComposingChanged FINAL REVISION 2) + // 2.3 (Qt 5.10) Q_PROPERTY(bool wrap READ wrap WRITE setWrap NOTIFY wrapChanged FINAL REVISION 3) public: @@ -112,6 +113,7 @@ public: bool isInputMethodComposing() const; + // 2.3 (Qt 5.10) bool wrap() const; void setWrap(bool wrap); @@ -132,6 +134,7 @@ Q_SIGNALS: Q_REVISION(2) void valueModified(); Q_REVISION(2) void inputMethodHintsChanged(); Q_REVISION(2) void inputMethodComposingChanged(); + // 2.3 (Qt 5.10) Q_REVISION(3) void wrapChanged(); protected: diff --git a/src/quicktemplates2/qquickstackview_p.h b/src/quicktemplates2/qquickstackview_p.h index fcbf0a93..2cddb800 100644 --- a/src/quicktemplates2/qquickstackview_p.h +++ b/src/quicktemplates2/qquickstackview_p.h @@ -72,6 +72,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickStackView : public QQuickControl Q_PROPERTY(QQuickTransition *pushExit READ pushExit WRITE setPushExit NOTIFY pushExitChanged FINAL) Q_PROPERTY(QQuickTransition *replaceEnter READ replaceEnter WRITE setReplaceEnter NOTIFY replaceEnterChanged FINAL) Q_PROPERTY(QQuickTransition *replaceExit READ replaceExit WRITE setReplaceExit NOTIFY replaceExitChanged FINAL) + // 2.3 (Qt 5.10) Q_PROPERTY(bool empty READ isEmpty NOTIFY emptyChanged FINAL REVISION 3) public: @@ -135,6 +136,7 @@ public: Q_INVOKABLE void pop(QQmlV4Function *args); Q_INVOKABLE void replace(QQmlV4Function *args); + // 2.3 (Qt 5.10) bool isEmpty() const; public Q_SLOTS: @@ -150,6 +152,7 @@ Q_SIGNALS: void pushExitChanged(); void replaceEnterChanged(); void replaceExitChanged(); + // 2.3 (Qt 5.10) Q_REVISION(3) void emptyChanged(); protected: diff --git a/src/quicktemplates2/qquickswipeview_p.h b/src/quicktemplates2/qquickswipeview_p.h index 82db6457..03f6cefa 100644 --- a/src/quicktemplates2/qquickswipeview_p.h +++ b/src/quicktemplates2/qquickswipeview_p.h @@ -62,6 +62,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickSwipeView : public QQuickContainer Q_PROPERTY(bool interactive READ isInteractive WRITE setInteractive NOTIFY interactiveChanged FINAL REVISION 1) // 2.2 (Qt 5.9) Q_PROPERTY(Qt::Orientation orientation READ orientation WRITE setOrientation NOTIFY orientationChanged FINAL REVISION 2) + // 2.3 (Qt 5.10) Q_PROPERTY(bool horizontal READ isHorizontal NOTIFY orientationChanged FINAL REVISION 3) Q_PROPERTY(bool vertical READ isVertical NOTIFY orientationChanged FINAL REVISION 3) @@ -78,6 +79,7 @@ public: Qt::Orientation orientation() const; void setOrientation(Qt::Orientation orientation); + // 2.3 (Qt 5.10) bool isHorizontal() const; bool isVertical() const; diff --git a/src/quicktemplates2/qquicktextarea_p.h b/src/quicktemplates2/qquicktextarea_p.h index 0c3a6c65..26799532 100644 --- a/src/quicktemplates2/qquicktextarea_p.h +++ b/src/quicktemplates2/qquicktextarea_p.h @@ -71,6 +71,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickTextArea : public QQuickTextEdit // 2.1 (Qt 5.8) Q_PROPERTY(bool hovered READ isHovered NOTIFY hoveredChanged FINAL REVISION 1) Q_PROPERTY(bool hoverEnabled READ isHoverEnabled WRITE setHoverEnabled RESET resetHoverEnabled NOTIFY hoverEnabledChanged FINAL REVISION 1) + // 2.3 (Qt 5.10) Q_PROPERTY(QPalette palette READ palette WRITE setPalette RESET resetPalette NOTIFY paletteChanged FINAL REVISION 3) public: @@ -101,6 +102,7 @@ public: void setHoverEnabled(bool enabled); void resetHoverEnabled(); + // 2.3 (Qt 5.10) QPalette palette() const; void setPalette(const QPalette &palette); void resetPalette(); @@ -118,6 +120,7 @@ Q_SIGNALS: Q_REVISION(1) void released(QQuickMouseEvent *event); Q_REVISION(1) void hoveredChanged(); Q_REVISION(1) void hoverEnabledChanged(); + // 2.3 (Qt 5.10) Q_REVISION(3) void paletteChanged(); protected: diff --git a/src/quicktemplates2/qquicktextfield_p.h b/src/quicktemplates2/qquicktextfield_p.h index dafe1c30..7dab0caf 100644 --- a/src/quicktemplates2/qquicktextfield_p.h +++ b/src/quicktemplates2/qquicktextfield_p.h @@ -70,6 +70,7 @@ class Q_QUICKTEMPLATES2_PRIVATE_EXPORT QQuickTextField : public QQuickTextInput // 2.1 (Qt 5.8) Q_PROPERTY(bool hovered READ isHovered NOTIFY hoveredChanged FINAL REVISION 1) Q_PROPERTY(bool hoverEnabled READ isHoverEnabled WRITE setHoverEnabled RESET resetHoverEnabled NOTIFY hoverEnabledChanged FINAL REVISION 1) + // 2.3 (Qt 5.10) Q_PROPERTY(QPalette palette READ palette WRITE setPalette RESET resetPalette NOTIFY paletteChanged FINAL REVISION 3) public: @@ -95,6 +96,7 @@ public: void setHoverEnabled(bool enabled); void resetHoverEnabled(); + // 2.3 (Qt 5.10) QPalette palette() const; void setPalette(const QPalette &palette); void resetPalette(); @@ -112,6 +114,7 @@ Q_SIGNALS: Q_REVISION(1) void released(QQuickMouseEvent *event); Q_REVISION(1) void hoveredChanged(); Q_REVISION(1) void hoverEnabledChanged(); + // 2.3 (Qt 5.10) Q_REVISION(3) void paletteChanged(); protected: |