mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-05 17:35:34 +08:00
refs #207, added simulator setup to CSimulatorInfo
* setup will provide some metadata about the flight simulator, such as path, version etc. * there will be a sim independent setup class, providing common information such as path, is simulator installed, etc. * a sim dependent class on top will provide the values specific to one sim * setup will contain the logic to fetch its values: setup->init
This commit is contained in:
49
src/blacksim/simulatorsetup.h
Normal file
49
src/blacksim/simulatorsetup.h
Normal file
@@ -0,0 +1,49 @@
|
||||
/* Copyright (C) 2013 VATSIM Community / contributors
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
#ifndef BLACKSIM_SIMSETUP_H
|
||||
#define BLACKSIM_SIMSETUP_H
|
||||
|
||||
#include "blackmisc/indexvariantmap.h"
|
||||
#include <QMap>
|
||||
#include <QString>
|
||||
|
||||
namespace BlackSim
|
||||
{
|
||||
/*!
|
||||
* \brief Simulator settings for MS Flight sims
|
||||
*/
|
||||
class CSimulatorSetup
|
||||
{
|
||||
protected:
|
||||
BlackMisc::CIndexVariantMap m_setup; //!< values describing the simulator setup (path, config files)
|
||||
|
||||
protected:
|
||||
//! Default constructor
|
||||
CSimulatorSetup() {}
|
||||
|
||||
//! Constructor
|
||||
CSimulatorSetup(const BlackMisc::CIndexVariantMap &map) : m_setup(map) {}
|
||||
|
||||
public:
|
||||
|
||||
enum
|
||||
{
|
||||
SetupSimPath
|
||||
};
|
||||
|
||||
//! Settings
|
||||
BlackMisc::CIndexVariantMap getSettings() const { return this->m_setup;}
|
||||
|
||||
//! Settings
|
||||
void setSettings(const BlackMisc::CIndexVariantMap &map);
|
||||
|
||||
//! Init, to be used where simulator runs
|
||||
void init();
|
||||
|
||||
};
|
||||
} // namespace
|
||||
|
||||
#endif // guard
|
||||
Reference in New Issue
Block a user