mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-23 15:25:35 +08:00
Aligned signatures for context and dialog to use sim.directory in validator
Ref T247 follow up
This commit is contained in:
committed by
Mat Sutcliffe
parent
347e584998
commit
d51b26cf8d
@@ -94,14 +94,27 @@ namespace BlackCore
|
||||
|
||||
// Validation
|
||||
m_validator = new CBackgroundValidation(this);
|
||||
m_validator->setCurrentSimulator(this->getSimulatorPluginInfo().getSimulator());
|
||||
connect(this, &CContextSimulator::simulatorChanged, m_validator, &CBackgroundValidation::setCurrentSimulator);
|
||||
this->setValidator(this->getSimulatorPluginInfo().getSimulator());
|
||||
connect(this, &CContextSimulator::simulatorChanged, this, &CContextSimulator::setValidator);
|
||||
connect(m_validator, &CBackgroundValidation::validated, this, &CContextSimulator::validatedModelSet, Qt::QueuedConnection);
|
||||
|
||||
m_validator->start(QThread::LowestPriority);
|
||||
m_validator->startUpdating(60);
|
||||
}
|
||||
|
||||
void CContextSimulator::setValidator(const CSimulatorInfo &simulator)
|
||||
{
|
||||
if (simulator.isSingleSimulator())
|
||||
{
|
||||
const QString simDir = m_simulatorSettings.getSimulatorDirectoryOrDefault(simulator);
|
||||
m_validator->setCurrentSimulator(simulator, simDir);
|
||||
}
|
||||
else
|
||||
{
|
||||
m_validator->setCurrentSimulator(CSimulatorInfo::None, {});
|
||||
}
|
||||
}
|
||||
|
||||
CContextSimulator *CContextSimulator::registerWithDBus(CDBusServer *server)
|
||||
{
|
||||
if (!server || m_mode != CCoreFacadeConfig::LocalInDBusServer) { return this; }
|
||||
@@ -1054,7 +1067,8 @@ namespace BlackCore
|
||||
if (!myself) { return; }
|
||||
if (m_aircraftMatcher.getModelSetCount() > MatchingLogMaxModelSetSize)
|
||||
{
|
||||
this->enableMatchingMessages(false);
|
||||
const MatchingLog log = CBuildConfig::isDebugBuild() ? MatchingLogAll : MatchingLogSimplified;
|
||||
this->enableMatchingMessages(log);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user