Ref T167, renaming LocalInDBusServer and verifyModelSet

This commit is contained in:
Klaus Basan
2017-10-10 00:15:50 +01:00
committed by Mathew Sutcliffe
parent 988a4791ab
commit 7a87f986e2
16 changed files with 22 additions and 22 deletions

View File

@@ -50,7 +50,7 @@ namespace BlackCore
//! Using local implementing object?
bool isUsingImplementingObject() const
{
return m_mode == CCoreFacadeConfig::Local || m_mode == CCoreFacadeConfig::LocalInDbusServer;
return m_mode == CCoreFacadeConfig::Local || m_mode == CCoreFacadeConfig::LocalInDBusServer;
}
//! Local or remote object?

View File

@@ -37,7 +37,7 @@ namespace BlackCore
switch (mode)
{
case CCoreFacadeConfig::Local:
case CCoreFacadeConfig::LocalInDbusServer:
case CCoreFacadeConfig::LocalInDBusServer:
return (new CContextApplication(mode, parent))->registerWithDBus(server);
case CCoreFacadeConfig::Remote:
return new CContextApplicationProxy(BlackMisc::CDBusServer::coreServiceName(), connection, mode, parent);

View File

@@ -34,7 +34,7 @@ namespace BlackCore
CContextApplication *CContextApplication::registerWithDBus(BlackMisc::CDBusServer *server)
{
if (!server || m_mode != CCoreFacadeConfig::LocalInDbusServer) { return this; }
if (!server || m_mode != CCoreFacadeConfig::LocalInDBusServer) { return this; }
server->addObject(IContextApplication::ObjectPath(), this);
return this;
}

View File

@@ -50,7 +50,7 @@ namespace BlackCore
switch (mode)
{
case CCoreFacadeConfig::Local:
case CCoreFacadeConfig::LocalInDbusServer:
case CCoreFacadeConfig::LocalInDBusServer:
return (new CContextAudio(mode, runtime))->registerWithDBus(server);
case CCoreFacadeConfig::Remote:
return new CContextAudioProxy(BlackMisc::CDBusServer::coreServiceName(), conn, mode, runtime);

View File

@@ -94,7 +94,7 @@ namespace BlackCore
CContextAudio *CContextAudio::registerWithDBus(CDBusServer *server)
{
if (!server || m_mode != CCoreFacadeConfig::LocalInDbusServer) { return this; }
if (!server || m_mode != CCoreFacadeConfig::LocalInDBusServer) { return this; }
server->addObject(IContextAudio::ObjectPath(), this);
return this;
}

View File

@@ -23,7 +23,7 @@ namespace BlackCore
switch (mode)
{
case CCoreFacadeConfig::Local:
case CCoreFacadeConfig::LocalInDbusServer:
case CCoreFacadeConfig::LocalInDBusServer:
return (new CContextNetwork(mode, runtime))->registerWithDBus(server);
case CCoreFacadeConfig::Remote:
return new CContextNetworkProxy(BlackMisc::CDBusServer::coreServiceName(), connection, mode, runtime);

View File

@@ -94,7 +94,7 @@ namespace BlackCore
CContextNetwork *CContextNetwork::registerWithDBus(BlackMisc::CDBusServer *server)
{
if (!server || m_mode != CCoreFacadeConfig::LocalInDbusServer) return this;
if (!server || m_mode != CCoreFacadeConfig::LocalInDBusServer) return this;
server->addObject(IContextNetwork::ObjectPath(), this);
return this;
}

View File

@@ -30,7 +30,7 @@ namespace BlackCore
switch (mode)
{
case CCoreFacadeConfig::Local:
case CCoreFacadeConfig::LocalInDbusServer:
case CCoreFacadeConfig::LocalInDBusServer:
return (new CContextOwnAircraft(mode, parent))->registerWithDBus(server);
case CCoreFacadeConfig::Remote:
return new CContextOwnAircraftProxy(BlackMisc::CDBusServer::coreServiceName(), conn, mode, parent);

View File

@@ -73,7 +73,7 @@ namespace BlackCore
CContextOwnAircraft *CContextOwnAircraft::registerWithDBus(CDBusServer *server)
{
if (!server || m_mode != CCoreFacadeConfig::LocalInDbusServer) return this;
if (!server || m_mode != CCoreFacadeConfig::LocalInDBusServer) return this;
server->addObject(IContextOwnAircraft::ObjectPath(), this);
return this;
}

View File

@@ -45,7 +45,7 @@ namespace BlackCore
switch (mode)
{
case CCoreFacadeConfig::Local:
case CCoreFacadeConfig::LocalInDbusServer:
case CCoreFacadeConfig::LocalInDBusServer:
return (new CContextSimulator(mode, parent))->registerWithDBus(server);
case CCoreFacadeConfig::Remote:
return new CContextSimulatorProxy(BlackMisc::CDBusServer::coreServiceName(), conn, mode, parent);

View File

@@ -70,7 +70,7 @@ namespace BlackCore
CContextSimulator *CContextSimulator::registerWithDBus(CDBusServer *server)
{
if (!server || this->m_mode != CCoreFacadeConfig::LocalInDbusServer) return this;
if (!server || this->m_mode != CCoreFacadeConfig::LocalInDBusServer) return this;
server->addObject(CContextSimulator::ObjectPath(), this);
return this;
}

View File

@@ -15,12 +15,12 @@ namespace BlackCore
{
return (
// those 3 should decide whether we are running the server
this->m_network == LocalInDbusServer ||
this->m_ownAircraft == LocalInDbusServer ||
this->m_simulator == LocalInDbusServer ||
this->m_network == LocalInDBusServer ||
this->m_ownAircraft == LocalInDBusServer ||
this->m_simulator == LocalInDBusServer ||
// added as work around
this->m_audio == LocalInDbusServer
this->m_audio == LocalInDBusServer
);
}
@@ -61,7 +61,7 @@ namespace BlackCore
CCoreFacadeConfig CCoreFacadeConfig::remoteLocalAudio(const QString &dbusBootstrapAddress)
{
CCoreFacadeConfig cfg = CCoreFacadeConfig(CCoreFacadeConfig(CCoreFacadeConfig::Remote, dbusBootstrapAddress));
cfg.m_audio = CCoreFacadeConfig::LocalInDbusServer;
cfg.m_audio = CCoreFacadeConfig::LocalInDBusServer;
return cfg;
}

View File

@@ -27,7 +27,7 @@ namespace BlackCore
{
NotUsed, //!< during shutdown or not used at all
Local, //!< in same process
LocalInDbusServer, //!< in same process, also registered in DBus, will be accessed by proxy objects too
LocalInDBusServer, //!< in same process, also registered in DBus, will be accessed by proxy objects too
Remote //!< proxy object
};
@@ -72,7 +72,7 @@ namespace BlackCore
ContextMode getModeSimulator() const { return this->m_simulator; }
//! local settings?
bool hasLocalSettings() const { return this->m_settings == Local || this->m_settings == LocalInDbusServer; }
bool hasLocalSettings() const { return this->m_settings == Local || this->m_settings == LocalInDBusServer; }
//! requires server (at least one in server)?
bool requiresDBusSever() const;

View File

@@ -391,7 +391,7 @@ void SwiftGuiStd::navigatorClosed()
this->showNormal();
}
void SwiftGuiStd::verifyDataAvailability()
void SwiftGuiStd::verifyModelSet()
{
const CSimulatorInfo sims = sGui->getIContextSimulator()->simulatorsWithInitializedModelSet();
if (sims.isNoSimulator())

View File

@@ -246,8 +246,8 @@ private:
//! Navigator dialog has been closed
void navigatorClosed();
//! Checks if data such as model set etc. are available
void verifyDataAvailability();
//! Checks if model set is available
void verifyModelSet();
//! The shared info objects have been loaded
void sharedInfoObjectsLoaded();

View File

@@ -154,7 +154,7 @@ void SwiftGuiStd::init()
emit sGui->startUpCompleted(true);
m_init = true;
QTimer::singleShot(2500, this, &SwiftGuiStd::verifyDataAvailability);
QTimer::singleShot(2500, this, &SwiftGuiStd::verifyModelSet);
if (!sGui->isNetworkAccessible())
{