mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-05 09:15:34 +08:00
refs #485, moved central GUI functionality to sGui
* allow to send status message to main window (from everywhere) * Use sGui::changedStylesheet where possible * message when model is stashed * improved application startup
This commit is contained in:
committed by
Mathew Sutcliffe
parent
b1353cefd4
commit
fb046ae1fb
@@ -105,7 +105,7 @@ namespace BlackCore
|
||||
}
|
||||
|
||||
// parsing itself is done
|
||||
if (this->m_startSetupReader)
|
||||
if (this->m_startSetupReader && !this->m_setupReader->isSetupSyncronized())
|
||||
{
|
||||
CStatusMessage m(this->requestReloadOfSetupAndVersion());
|
||||
if (m.isWarningOrAbove())
|
||||
@@ -132,7 +132,7 @@ namespace BlackCore
|
||||
{
|
||||
QCoreApplication::instance()->processEvents(QEventLoop::AllEvents, 250);
|
||||
}
|
||||
if (this->m_startUpCompleted)
|
||||
if (!this->m_startUpCompleted)
|
||||
{
|
||||
CLogMessage(this).error("Waiting for startup timed out");
|
||||
}
|
||||
@@ -250,6 +250,11 @@ namespace BlackCore
|
||||
|
||||
this->m_useContexts = true;
|
||||
this->m_coreFacadeConfig = coreConfig;
|
||||
|
||||
if (!this->m_useWebData)
|
||||
{
|
||||
this->useWebDataServices(CWebReaderFlags::AllReaders, CWebReaderFlags::FromCache);
|
||||
}
|
||||
return this->startCoreFacade(); // will do nothing if setup is not yet loaded
|
||||
}
|
||||
|
||||
@@ -371,16 +376,21 @@ namespace BlackCore
|
||||
{
|
||||
if (success)
|
||||
{
|
||||
if (!this->m_started)
|
||||
{
|
||||
// follow up startups
|
||||
bool s = this->startWebDataServices();
|
||||
this->m_started = s && this->startCoreFacade();
|
||||
}
|
||||
emit setupSyncronized();
|
||||
this->m_started = this->asyncWebAndContextStart();
|
||||
}
|
||||
this->m_startUpCompleted = true;
|
||||
}
|
||||
|
||||
bool CApplication::asyncWebAndContextStart()
|
||||
{
|
||||
if (this->m_started) { return true; }
|
||||
|
||||
// follow up startups
|
||||
bool s = this->startWebDataServices();
|
||||
return s && this->startCoreFacade();
|
||||
}
|
||||
|
||||
void CApplication::severeStartupProblem(const CStatusMessage &message)
|
||||
{
|
||||
CLogMessage(this).preformatted(message);
|
||||
|
||||
@@ -198,6 +198,9 @@ namespace BlackCore
|
||||
virtual void gracefulShutdown();
|
||||
|
||||
signals:
|
||||
//! Setup syncronized
|
||||
void setupSyncronized();
|
||||
|
||||
//! Facade started
|
||||
void coreFacadeStarted();
|
||||
|
||||
@@ -257,6 +260,9 @@ namespace BlackCore
|
||||
//! Init parser
|
||||
void initParser();
|
||||
|
||||
//! Async. start when setup is loaded
|
||||
bool asyncWebAndContextStart();
|
||||
|
||||
//! static init part
|
||||
static void initEnvironment();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user