From 55b738e65c8994868af6c9c1cc54edf5ae34babb Mon Sep 17 00:00:00 2001 From: Mathew Sutcliffe Date: Tue, 21 Mar 2017 01:52:17 +0000 Subject: [PATCH] refs #920 X-Plane support in CSimulatorInfo::getLocallyInstalledSimulators. --- src/blackmisc/simulation/simulatorinfo.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/blackmisc/simulation/simulatorinfo.cpp b/src/blackmisc/simulation/simulatorinfo.cpp index a3bea3b19..0ac2c2290 100644 --- a/src/blackmisc/simulation/simulatorinfo.cpp +++ b/src/blackmisc/simulation/simulatorinfo.cpp @@ -12,6 +12,7 @@ #include "blackmisc/simulation/simulatorplugininfo.h" #include "blackmisc/simulation/fscommon/fscommonutil.h" #include "blackmisc/simulation/simulatorinfo.h" +#include "blackmisc/simulation/xplane/xplaneutil.h" #include "blackmisc/comparefunctions.h" #include #include @@ -21,6 +22,7 @@ using namespace BlackConfig; using namespace BlackMisc; using namespace BlackMisc::Db; using namespace BlackMisc::Simulation::FsCommon; +using namespace BlackMisc::Simulation::XPlane; namespace BlackMisc { @@ -226,7 +228,6 @@ namespace BlackMisc bool fs9 = false; bool fsx = false; bool p3d = false; - bool xp = false; if (CBuildConfig::isRunningOnWindowsNtPlatform()) { @@ -244,7 +245,7 @@ namespace BlackMisc !CFsCommonUtil::p3dSimObjectsDir().isEmpty(); } - xp = true; //! \todo XP resolution for locally installed simulator + const bool xp = !CXPlaneUtil::xplaneRootDir().isEmpty(); sim.setSimulator(CSimulatorInfo::boolToFlag(fsx, fs9, xp, p3d)); return sim;