From 0e09aa0f2b64e8f62703a34018352cc3fa18fffc Mon Sep 17 00:00:00 2001 From: Sze Howe Koh Date: Sun, 9 Mar 2014 13:02:01 +0800 Subject: [PATCH] Doc: Qt QML: Document signals (not handlers) under \qmlsignal Task-number: QTBUG-35846 Change-Id: I989617865a79bfbf1f1ffd3b105598025dde54c5 Reviewed-by: Mitch Curtis Reviewed-by: Jerome Pasion --- src/qml/types/qqmldelegatemodel.cpp | 6 ++++-- src/qml/types/qqmlinstantiator.cpp | 14 +++++++++----- src/qml/types/qqmltimer.cpp | 6 ++++-- 3 files changed, 17 insertions(+), 9 deletions(-) diff --git a/src/qml/types/qqmldelegatemodel.cpp b/src/qml/types/qqmldelegatemodel.cpp index e0d9094..910cec9 100644 --- a/src/qml/types/qqmldelegatemodel.cpp +++ b/src/qml/types/qqmldelegatemodel.cpp @@ -2915,15 +2915,17 @@ void QQmlDelegateModelGroup::move(QQmlV4Function *args) } /*! - \qmlsignal QtQml.Models::DelegateModelGroup::onChanged(array removed, array inserted) + \qmlsignal QtQml.Models::DelegateModelGroup::changed(array removed, array inserted) - This handler is called when items have been removed from or inserted into the group. + This signal is emitted when items have been removed from or inserted into the group. Each object in the \a removed and \a inserted arrays has two values; the \e index of the first item inserted or removed and a \e count of the number of consecutive items inserted or removed. Each index is adjusted for previous changes with all removed items preceding any inserted items. + + The corresponding handler is \c onChanged. */ //============================================================================ diff --git a/src/qml/types/qqmlinstantiator.cpp b/src/qml/types/qqmlinstantiator.cpp index c28cfad..724a768 100644 --- a/src/qml/types/qqmlinstantiator.cpp +++ b/src/qml/types/qqmlinstantiator.cpp @@ -212,22 +212,26 @@ QQmlInstantiator::~QQmlInstantiator() } /*! - \qmlsignal QtQml::Instantiator::onObjectAdded(int index, QtObject object) + \qmlsignal QtQml::Instantiator::objectAdded(int index, QtObject object) - This handler is called when an object is added to the Instantiator. The \a index + This signal is emitted when an object is added to the Instantiator. The \a index parameter holds the index which the object has been given, and the \a object parameter holds the \l QtObject that has been added. + + The corresponding handler is \c onObjectAdded. */ /*! - \qmlsignal QtQml::Instantiator::onObjectRemoved(int index, QtObject object) + \qmlsignal QtQml::Instantiator::objectRemoved(int index, QtObject object) - This handler is called when an object is added to the Instantiator. The \a index + This signal is emitted when an object is removed from the Instantiator. The \a index parameter holds the index which the object had been given, and the \a object parameter holds the \l QtObject that has been removed. Do not keep a reference to \a object if it was created by this Instantiator, as - in these cases it will be deleted shortly after the handler is called. + in these cases it will be deleted shortly after the signal is handled. + + The corresponding handler is \c onObjectRemoved. */ /*! \qmlproperty bool QtQml::Instantiator::active diff --git a/src/qml/types/qqmltimer.cpp b/src/qml/types/qqmltimer.cpp index 32018c1..b9e28b8 100644 --- a/src/qml/types/qqmltimer.cpp +++ b/src/qml/types/qqmltimer.cpp @@ -302,9 +302,11 @@ void QQmlTimer::componentComplete() } /*! - \qmlsignal QtQml::Timer::onTriggered() + \qmlsignal QtQml::Timer::triggered() - This handler is called when the Timer is triggered. + This signal is emitted when the Timer times out. + + The corresponding handler is \c onTriggered. */ void QQmlTimer::ticked() { -- 2.7.4