Ref T111, emit signal simulatorPluginChanged after function completes

This commit is contained in:
Klaus Basan
2017-08-02 17:47:25 +02:00
committed by Mathew Sutcliffe
parent 4a9ab8c3d7
commit c066ffcd28

View File

@@ -314,9 +314,12 @@ namespace BlackCore
m_simulatorPlugin.first = simulatorPluginInfo;
m_simulatorPlugin.second = simulator;
//! \fixme KB 7/2017 wonder if it was better to force an Qt::QueuedConnection emit by calling CTimer::singleShot
//! Replace this comment by an info comment after review, or change
emit simulatorPluginChanged(simulatorPluginInfo);
// Emit signal after this function completes
QTimer::singleShot(0, this, [ = ]
{
emit this->simulatorPluginChanged(simulatorPluginInfo);
});
CLogMessage(this).info("Simulator plugin loaded: '%1' connected: %2")
<< simulatorPluginInfo.toQString(true)
<< boolToYesNo(connected);