Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
|
Groups actions together. More...
Static Public Member Functions | |
static bool | changeEnabled (QQuickAction *action, bool enabled) |
static void | actions_append (QQmlListProperty< QQuickAction > *prop, QQuickAction *obj) |
static qsizetype | actions_count (QQmlListProperty< QQuickAction > *prop) |
static QQuickAction * | actions_at (QQmlListProperty< QQuickAction > *prop, qsizetype index) |
static void | actions_clear (QQmlListProperty< QQuickAction > *prop) |
Static Public Member Functions inherited from QObjectPrivate | |
static bool | removeConnection (Connection *c) |
static QObjectPrivate * | get (QObject *o) |
static const QObjectPrivate * | get (const QObject *o) |
template<typename Func1 , typename Func2 > | |
static QMetaObject::Connection | connect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiverPrivate, Func2 slot, Qt::ConnectionType type=Qt::AutoConnection) |
template<typename Func1 , typename Func2 > | |
static bool | disconnect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiverPrivate, Func2 slot) |
static QMetaObject::Connection | connectImpl (const QObject *sender, int signal_index, const QObject *receiver, void **slot, QtPrivate::QSlotObjectBase *slotObj, int type, const int *types, const QMetaObject *senderMetaObject) |
static QMetaObject::Connection | connect (const QObject *sender, int signal_index, QtPrivate::QSlotObjectBase *slotObj, Qt::ConnectionType type) |
static QMetaObject::Connection | connect (const QObject *sender, int signal_index, const QObject *receiver, QtPrivate::QSlotObjectBase *slotObj, Qt::ConnectionType type) |
static bool | disconnect (const QObject *sender, int signal_index, void **slot) |
static bool | disconnect (const QObject *sender, int signal_index, const QObject *receiver, void **slot) |
Public Attributes | ||
bool | enabled = true | |
bool | exclusive = true | |
QPointer< QQuickAction > | checkedAction | |
QList< QQuickAction * > | actions | |
Public Attributes inherited from QObjectPrivate | ||
ExtraData * | extraData | |
QAtomicPointer< QThreadData > | threadData | |
QAtomicPointer< ConnectionData > | connections | |
union { | ||
QObject * currentChildBeingDeleted | ||
QAbstractDeclarativeData * declarativeData | ||
}; | ||
QAtomicPointer< QtSharedPointer::ExternalRefCountData > | sharedRefcount | |
Public Attributes inherited from QObjectData | ||
QObject * | q_ptr | |
QObject * | parent | |
QObjectList | children | |
uint | isWidget: 1 | |
uint | blockSig: 1 | |
uint | wasDeleted: 1 | |
uint | isDeletingChildren: 1 | |
uint | sendChildEvents: 1 | |
uint | receiveChildEvents: 1 | |
uint | isWindow: 1 | |
uint | deleteLaterCalled: 1 | |
uint | isQuickItem: 1 | |
uint | willBeWidget: 1 | |
uint | wasWidget: 1 | |
uint | receiveParentEvents: 1 | |
uint | unused: 20 | |
QAtomicInt | postedEvents | |
QDynamicMetaObjectData * | metaObject | |
QBindingStorage | bindingStorage | |
Additional Inherited Members | |
Public Types inherited from QObjectPrivate | |
typedef void(* | StaticMetaCallFunction) (QObject *, QMetaObject::Call, int, void **) |
using | ConnectionDataPointer = QExplicitlySharedDataPointer<ConnectionData> |
Groups actions together.
\qmltype ActionGroup \inherits QtObject
! \instantiates QQuickActionGroup \inqmlmodule QtQuick.Controls
ActionGroup is a non-visual group of actions. A mutually \l exclusive action group is used with actions where only one of the options can be selected at a time.
The most straight-forward way to use ActionGroup is to declare actions as children of the group.
Alternatively, the \l group attached property allows declaring the actions elsewhere and assigning them to a specific group.
More advanced use cases can be handled using the addAction()
and removeAction()
methods.
\qmlsignal QtQuick.Controls::ActionGroup::triggered(Action action)
This signal is emitted when an action in the group has been triggered.
This signal is convenient for implementing a common signal handler for all actions in the same group.
Definition at line 109 of file qquickactiongroup.cpp.
void QQuickActionGroupPrivate::_q_updateCurrent | ( | ) |
Definition at line 149 of file qquickactiongroup.cpp.
References actions, checkedAction, QListSpecialMethodsBase< T >::contains(), exclusive, and QQuickAction::isChecked().
Referenced by QQuickActionGroup::addAction(), clear(), and QQuickActionGroup::removeAction().
|
static |
Definition at line 166 of file qquickactiongroup.cpp.
References QQuickActionGroup::addAction().
|
static |
Definition at line 178 of file qquickactiongroup.cpp.
References actions, and QList< T >::value().
|
static |
Definition at line 184 of file qquickactiongroup.cpp.
References clear(), emit, QMetaObject::invokeMethod(), and Qt::QueuedConnection.
|
static |
Definition at line 172 of file qquickactiongroup.cpp.
References actions, and QList< T >::size().
void QQuickActionGroupPrivate::actionTriggered | ( | ) |
Definition at line 141 of file qquickactiongroup.cpp.
References emit.
Referenced by QQuickActionGroup::addAction(), clear(), and QQuickActionGroup::removeAction().
|
static |
Definition at line 161 of file qquickactiongroup.cpp.
References QQuickActionPrivate::get(), and QQuickAction::isEnabled().
void QQuickActionGroupPrivate::clear | ( | ) |
Definition at line 131 of file qquickactiongroup.cpp.
References _q_updateCurrent(), actions, actionTriggered(), QQuickAction::checkedChanged(), QList< T >::clear(), QObjectPrivate::disconnect(), QQuickActionPrivate::get(), and QQuickAction::triggered().
Referenced by actions_clear().
QList<QQuickAction*> QQuickActionGroupPrivate::actions |
Definition at line 128 of file qquickactiongroup.cpp.
Referenced by _q_updateCurrent(), actions_at(), actions_count(), and clear().
QPointer<QQuickAction> QQuickActionGroupPrivate::checkedAction |
Definition at line 127 of file qquickactiongroup.cpp.
Referenced by _q_updateCurrent().
bool QQuickActionGroupPrivate::enabled = true |
Definition at line 125 of file qquickactiongroup.cpp.
bool QQuickActionGroupPrivate::exclusive = true |
Definition at line 126 of file qquickactiongroup.cpp.
Referenced by _q_updateCurrent().