aboutsummaryrefslogtreecommitdiffstats
path: root/src/quicktemplates2/qquickmenu.cpp
diff options
context:
space:
mode:
authorJ-P Nurmi <jpnurmi@qt.io>2017-11-06 14:18:12 +0100
committerJ-P Nurmi <jpnurmi@qt.io>2017-11-06 14:15:04 +0000
commit8a56c3322f72d0ec1d55c3bfb679355919f27e34 (patch)
tree0ee4e2976af445207cde9e1743eadc4074abc31e /src/quicktemplates2/qquickmenu.cpp
parentc39b126a77e27296ef82a1634753c775cc5a93fb (diff)
Re-order revision 3 members and add explanatory comments
We've come to realize that even though it's tempting to group similar properties together, organizing the API so that revisions are grouped together makes future maintenance more pleasant. It's a lot easier to to see what was added and when. The same was done for earlier revisions in 5.9 in commit 430fe83. Change-Id: I738d7fdadd348c21737228c37d0f31e39b37f8e7 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
Diffstat (limited to 'src/quicktemplates2/qquickmenu.cpp')
-rw-r--r--src/quicktemplates2/qquickmenu.cpp26
1 files changed, 13 insertions, 13 deletions
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);