mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-23 15:25:35 +08:00
refs #786, prepare contexts for matching messages
In same step cleaned up contexts a bit * added function for model set strings * renamed functions to getModelSet... instead of installed models (the set is smaller and is what we want to use with DBus) * signal when debug/log flags changed * removed some \copydoc * allow to enable/disable rev.lookup/matching messages * removed reload model function (dangling)
This commit is contained in:
@@ -63,6 +63,7 @@ namespace BlackCore
|
||||
"weatherGridReceived", this, SIGNAL(weatherGridReceived(BlackMisc::Weather::CWeatherGrid, BlackMisc::CIdentifier)));
|
||||
Q_ASSERT(s);
|
||||
Q_UNUSED(s);
|
||||
this->relayBaseClassSignals(serviceName, connection, IContextSimulator::ObjectPath(), IContextSimulator::InterfaceName());
|
||||
}
|
||||
|
||||
CSimulatorPluginInfoList CContextSimulatorProxy::getAvailableSimulatorPlugins() const
|
||||
@@ -80,24 +81,24 @@ namespace BlackCore
|
||||
return m_dBusInterface->callDBusRet<BlackMisc::Aviation::CAirportList>(QLatin1Literal("getAirportsInRange"));
|
||||
}
|
||||
|
||||
CAircraftModelList CContextSimulatorProxy::getInstalledModels() const
|
||||
CAircraftModelList CContextSimulatorProxy::getModelSet() const
|
||||
{
|
||||
return m_dBusInterface->callDBusRet<BlackMisc::Simulation::CAircraftModelList>(QLatin1Literal("getInstalledModels"));
|
||||
return m_dBusInterface->callDBusRet<BlackMisc::Simulation::CAircraftModelList>(QLatin1Literal("getModelSet"));
|
||||
}
|
||||
|
||||
CAircraftModelList CContextSimulatorProxy::getInstalledModelsStartingWith(const QString modelString) const
|
||||
QStringList CContextSimulatorProxy::getModelSetStrings() const
|
||||
{
|
||||
return m_dBusInterface->callDBusRet<BlackMisc::Simulation::CAircraftModelList>(QLatin1Literal("getInstalledModelsStartingWith"), modelString);
|
||||
return m_dBusInterface->callDBusRet<QStringList>(QLatin1Literal("getModelSetStrings"));
|
||||
}
|
||||
|
||||
int CContextSimulatorProxy::getInstalledModelsCount() const
|
||||
CAircraftModelList CContextSimulatorProxy::getModelSetModelsStartingWith(const QString modelString) const
|
||||
{
|
||||
return m_dBusInterface->callDBusRet<int>(QLatin1Literal("getInstalledModelsCount"));
|
||||
return m_dBusInterface->callDBusRet<BlackMisc::Simulation::CAircraftModelList>(QLatin1Literal("getModelSetModelsStartingWith"), modelString);
|
||||
}
|
||||
|
||||
void CContextSimulatorProxy::reloadInstalledModels()
|
||||
int CContextSimulatorProxy::getModelSetCount() const
|
||||
{
|
||||
m_dBusInterface->callDBus(QLatin1Literal("reloadInstalledModels"));
|
||||
return m_dBusInterface->callDBusRet<int>(QLatin1Literal("getModelSetCount"));
|
||||
}
|
||||
|
||||
BlackMisc::Simulation::CSimulatorPluginInfo CContextSimulatorProxy::getSimulatorPluginInfo() const
|
||||
@@ -199,5 +200,20 @@ namespace BlackCore
|
||||
{
|
||||
m_dBusInterface->callDBus(QLatin1Literal("enableDebugMessages"), driver, interpolator);
|
||||
}
|
||||
|
||||
CStatusMessageList CContextSimulatorProxy::getMatchingMessages(const BlackMisc::Aviation::CCallsign &callsign) const
|
||||
{
|
||||
return m_dBusInterface->callDBusRet<BlackMisc::CStatusMessageList>(QLatin1Literal("getMatchingMessages"), callsign);
|
||||
}
|
||||
|
||||
bool CContextSimulatorProxy::isMatchingMessagesEnabled() const
|
||||
{
|
||||
return m_dBusInterface->callDBusRet<bool>(QLatin1Literal("isMatchingMessagesEnabled"));
|
||||
}
|
||||
|
||||
void CContextSimulatorProxy::enableMatchingMessages(bool enabled)
|
||||
{
|
||||
m_dBusInterface->callDBus(QLatin1Literal("enableMatchingMessages"), enabled);
|
||||
}
|
||||
} // namespace
|
||||
} // namespace
|
||||
|
||||
Reference in New Issue
Block a user