A unified model that concatenates multiple arranger object models.
More...
#include <src/gui/backend/unified_arranger_objects_model.h>
|
| | UnifiedArrangerObjectsModel (QObject *parent=nullptr) |
| | Constructor for the unified arranger objects model.
|
| Q_INVOKABLE void | addSourceModel (QAbstractItemModel *model) |
| | Adds a source model to the unified model.
|
| Q_INVOKABLE void | removeSourceModel (QAbstractItemModel *model) |
| | Removes a source model from the unified model.
|
| Q_INVOKABLE QModelIndex | mapFromSource (const QModelIndex &sourceIndex) const |
| | Maps a source model index to the unified model index.
|
| Q_INVOKABLE QModelIndex | mapToSource (const QModelIndex &proxyIndex) const |
| | Maps a unified model index to the source model index.
|
A unified model that concatenates multiple arranger object models.
This class provides a single interface to access objects from multiple source models, allowing unified selection and manipulation across different arranger object types. It inherits from QConcatenateTablesProxyModel to combine multiple models into one.
Definition at line 21 of file unified_arranger_objects_model.h.
◆ UnifiedArrangerObjectsModel()
| zrythm::gui::UnifiedArrangerObjectsModel::UnifiedArrangerObjectsModel |
( |
QObject * | parent = nullptr | ) |
|
|
explicit |
Constructor for the unified arranger objects model.
- Parameters
-
| parent | Parent QObject (optional). |
◆ addSourceModel()
| Q_INVOKABLE void zrythm::gui::UnifiedArrangerObjectsModel::addSourceModel |
( |
QAbstractItemModel * | model | ) |
|
Adds a source model to the unified model.
- Parameters
-
◆ mapFromSource()
| Q_INVOKABLE QModelIndex zrythm::gui::UnifiedArrangerObjectsModel::mapFromSource |
( |
const QModelIndex & | sourceIndex | ) |
const |
Maps a source model index to the unified model index.
- Parameters
-
| sourceIndex | The index in the source model. |
- Returns
- The corresponding index in the unified model.
◆ mapToSource()
| Q_INVOKABLE QModelIndex zrythm::gui::UnifiedArrangerObjectsModel::mapToSource |
( |
const QModelIndex & | proxyIndex | ) |
const |
Maps a unified model index to the source model index.
- Parameters
-
| proxyIndex | The index in the unified model. |
- Returns
- The corresponding index in the source model.
◆ removeSourceModel()
| Q_INVOKABLE void zrythm::gui::UnifiedArrangerObjectsModel::removeSourceModel |
( |
QAbstractItemModel * | model | ) |
|
Removes a source model from the unified model.
- Parameters
-
| model | The model to remove. |
The documentation for this class was generated from the following file: