* @brief Replaces the action at actionId and emits actionsChanged. */
| 3342 | * @brief Replaces the action at actionId and emits actionsChanged. |
| 3343 | */ |
| 3344 | void DataModel::ProjectModel::updateAction(const int actionId, |
| 3345 | const DataModel::Action& action, |
| 3346 | const bool rebuildTree) |
| 3347 | { |
| 3348 | if (actionId < 0 || static_cast<size_t>(actionId) >= m_actions.size()) |
| 3349 | return; |
| 3350 | |
| 3351 | m_actions[actionId] = action; |
| 3352 | |
| 3353 | if (rebuildTree) |
| 3354 | Q_EMIT actionsChanged(); |
| 3355 | |
| 3356 | setModified(true); |
| 3357 | } |
| 3358 | |
| 3359 | //-------------------------------------------------------------------------------------------------- |
| 3360 | // Group / dataset / action mutation |
no test coverage detected