Mercurial > hg > svapp
changeset 700:7669c8cc869d
Use layer->getSourceModel
author | Chris Cannam |
---|---|
date | Fri, 02 Aug 2019 16:50:20 +0100 |
parents | 46ab91e26bfe |
children | e3dc68cc07f9 |
files | framework/Document.cpp |
diffstat | 1 files changed, 3 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/framework/Document.cpp Thu Aug 01 15:21:13 2019 +0100 +++ b/framework/Document.cpp Fri Aug 02 16:50:20 2019 +0100 @@ -1356,12 +1356,9 @@ if (i->first && !i->second.empty()) { // Layer exists, is in views ModelId modelId = i->first->getModel(); - if (auto model = ModelById::get(modelId)) { - used.insert(modelId); - if (!model->getSourceModel().isNone()) { - used.insert(model->getSourceModel()); - } - } + ModelId sourceId = i->first->getSourceModel(); + if (!modelId.isNone()) used.insert(modelId); + if (!sourceId.isNone()) used.insert(sourceId); } }