| 2008 | } |
| 2009 | |
| 2010 | int EffectStackModel::effectRow(const QString &assetId, int eid, bool enabledOnly) const |
| 2011 | { |
| 2012 | for (int i = 0; i < rootItem->childCount(); ++i) { |
| 2013 | if (eid > -1) { |
| 2014 | if (rootItem->child(i)->getId() == eid) { |
| 2015 | return i; |
| 2016 | } |
| 2017 | } else { |
| 2018 | auto effect = std::static_pointer_cast<EffectItemModel>(rootItem->child(i)); |
| 2019 | if (effect->getAssetId() == assetId) { |
| 2020 | if (!enabledOnly || effect->isAssetEnabled()) { |
| 2021 | return i; |
| 2022 | } |
| 2023 | } |
| 2024 | } |
| 2025 | } |
| 2026 | return -1; |
| 2027 | } |
| 2028 | |
| 2029 | QVariantList EffectStackModel::getEffectZones() const |
| 2030 | { |
no test coverage detected