Ref T177, added direct write flag because only direct writes require a consolidation

This commit is contained in:
Klaus Basan
2017-10-30 02:09:39 +01:00
parent 2e307555a2
commit 3215a2e756
4 changed files with 5 additions and 4 deletions

View File

@@ -156,11 +156,12 @@ namespace BlackCore
return true;
}
void CBackgroundDataUpdater::onModelsPublished(const CAircraftModelList &modelsPublished)
void CBackgroundDataUpdater::onModelsPublished(const CAircraftModelList &modelsPublished, bool directWrite)
{
if (!this->doWorkCheck()) { return; }
if (modelsPublished.isEmpty()) { return; }
if (!m_updatePublishedModels) { return; }
if (!directWrite) { return; } // those models are CRs and have to be released first
emit this->consolidating(true);
this->syncModelOrModelSetCacheWithDbData(m_modelCaches, modelsPublished);