Make simulator listeners safe against multiple starts

refs #909
This commit is contained in:
Roland Winklmeier
2017-03-25 18:57:57 +01:00
committed by Mathew Sutcliffe
parent 0eaab1753d
commit aafe211b5c
8 changed files with 45 additions and 23 deletions

View File

@@ -83,4 +83,18 @@ namespace BlackCore
return m_info.toQString();
}
void ISimulatorListener::start()
{
if (m_isRunning) { return; }
m_isRunning = true;
startImpl();
}
void ISimulatorListener::stop()
{
if(!m_isRunning) { return; }
stopImpl();
m_isRunning = false;
}
} // namespace