improve update events

This commit is contained in:
arcan1s
2015-07-20 00:21:39 +03:00
parent c7d998eb12
commit 1110929b14
13 changed files with 96 additions and 65 deletions

View File

@ -146,12 +146,12 @@ void ExtUpgrade::setApiVersion(const int _apiVersion)
}
void ExtUpgrade::setActive(const bool state)
void ExtUpgrade::setActive(const bool _state)
{
if (debug) qDebug() << PDEBUG;
if (debug) qDebug() << PDEBUG << ":" << "State" << state;
if (debug) qDebug() << PDEBUG << ":" << "State" << _state;
m_active = state;
m_active = _state;
}
@ -251,7 +251,7 @@ int ExtUpgrade::run()
if (!m_active) return value;
if ((times == 1) && (process->state() == QProcess::NotRunning))
process->start(QString("bash -c \"%1\"").arg(m_executable));
process->start(QString("sh -c \"%1\"").arg(m_executable));
else if (times >= m_interval)
times = 0;
times++;