From bb7ba4d62d3084c5448b9012e4a618c02395b087 Mon Sep 17 00:00:00 2001 From: Jens Bache-Wiig Date: Wed, 15 May 2013 16:30:05 +0200 Subject: Improve top-level index page for documentation - Adds Menus to the front page so that we can actually find essential types like Menu and Action. - Added a basic example for Action - I also added ExclusiveGroup to the Controls category to make it accessible. Change-Id: Ife980b786870d2bf07d709e024cb97396870e6c7 Reviewed-by: Gabriel de Dietrich Reviewed-by: Jerome Pasion --- src/controls/qquickaction.cpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'src/controls/qquickaction.cpp') diff --git a/src/controls/qquickaction.cpp b/src/controls/qquickaction.cpp index dc1f7bb9d..a597515f0 100644 --- a/src/controls/qquickaction.cpp +++ b/src/controls/qquickaction.cpp @@ -53,6 +53,7 @@ QT_BEGIN_NAMESPACE /*! \qmltype Action \instantiates QQuickAction + \ingroup applicationwindow \inqmlmodule QtQuick.Controls 1.0 \brief Action provides an abstract user interface action that can be bound to items @@ -65,6 +66,19 @@ QT_BEGIN_NAMESPACE automatically be checked. QtQuick Controls supports actions in \l Button, \l ToolButton, and \l MenuItem. + + Example: + \qml + Action { + id: openAction + text: "&Open" + shortcut: "Ctrl+O" + iconSource: "images/document-open.png" + onTriggered: fileDialog.open() + tooltip: "Open an Image" + } + \endqml + */ /*! -- cgit v1.2.3