forked from organicmaps/organicmaps
Set Framework::m_lowestMapsVersion only for version >= v2.
This commit is contained in:
parent
3124974e98
commit
3034891159
2 changed files with 5 additions and 3 deletions
|
@ -66,8 +66,6 @@ void Framework::AddMap(string const & file)
|
|||
|
||||
//threads::MutexGuard lock(m_modelSyn);
|
||||
int const version = m_model.AddMap(file);
|
||||
if (m_lowestMapVersion > version)
|
||||
m_lowestMapVersion = version;
|
||||
|
||||
// Now we do force delete of old (April 2011) maps.
|
||||
if (version == feature::DataHeader::v1)
|
||||
|
@ -76,6 +74,11 @@ void Framework::AddMap(string const & file)
|
|||
RemoveMap(file);
|
||||
VERIFY ( my::DeleteFileX(GetPlatform().WritablePathForFile(file)), () );
|
||||
}
|
||||
else
|
||||
{
|
||||
if (m_lowestMapVersion > version)
|
||||
m_lowestMapVersion = version;
|
||||
}
|
||||
}
|
||||
|
||||
void Framework::RemoveMap(string const & file)
|
||||
|
|
|
@ -13,7 +13,6 @@
|
|||
|
||||
#include "../geometry/distance_on_sphere.hpp"
|
||||
|
||||
#include "../base/logging.hpp"
|
||||
#include "../base/stl_add.hpp"
|
||||
|
||||
#include "../std/map.hpp"
|
||||
|
|
Loading…
Add table
Reference in a new issue