Ref T709, send XSwiftBusSettings when driver is connected

* send from swift -> XPlane side
* also send if settings on swift side are updated
This commit is contained in:
Klaus Basan
2019-07-26 16:48:44 +02:00
committed by Mat Sutcliffe
parent 42eb5477ec
commit f2bf038501
3 changed files with 43 additions and 9 deletions

View File

@@ -225,11 +225,14 @@ namespace BlackSimPlugin
//! Send/receive settings @{
bool sendXSwiftBusSettings();
bool receiveXSwiftBusSettings();
BlackMisc::Simulation::Settings::CXSwiftBusSettings receiveXSwiftBusSettings(bool &ok);
//! @}
//! Settings have changed
void onXSwiftBusSettingsChanged();
DBusMode m_dbusMode;
BlackMisc::CSetting<BlackMisc::Simulation::Settings::TXSwiftBusSettings> m_xSwiftBusServerSettings { this };
BlackMisc::CSetting<BlackMisc::Simulation::Settings::TXSwiftBusSettings> m_xSwiftBusServerSettings { this, &CSimulatorXPlane::onXSwiftBusSettingsChanged };
static constexpr qint64 TimeoutAdding = 10000;
QDBusConnection m_dBusConnection { "default" };
QDBusServiceWatcher *m_watcher { nullptr };