refs #791, also perform lookup in simulator plugin`s CSimulatorFsCommon::setOwnAircraftModel

This commit is contained in:
Klaus Basan
2016-10-29 04:07:33 +02:00
parent 4e2a01c1e4
commit 4478af119d
3 changed files with 12 additions and 2 deletions

View File

@@ -8,6 +8,7 @@
*/
#include "blackcore/simulatorcommon.h"
#include "blackcore/db/databaseutils.h"
#include "blackmisc/aviation/aircraftsituation.h"
#include "blackmisc/aviation/callsign.h"
#include "blackmisc/interpolator.h"
@@ -30,6 +31,7 @@ using namespace BlackMisc::Simulation;
using namespace BlackMisc::PhysicalQuantities;
using namespace BlackMisc::Simulation;
using namespace BlackMisc::Weather;
using namespace BlackCore::Db;
namespace BlackCore
{
@@ -162,6 +164,13 @@ namespace BlackCore
}
}
CAircraftModel CSimulatorCommon::reverseLookupModel(const CAircraftModel &model)
{
bool modified = false;
const CAircraftModel reverseModel = CDatabaseUtils::consolidateOwnAircraftModelWithDbData(model, false, &modified);
return reverseModel;
}
CAircraftModel CSimulatorCommon::getDefaultModel() const
{
return m_defaultModel;