implement script function

This commit is contained in:
arcan1s
2014-11-03 06:33:39 +03:00
parent a4af7ffc07
commit 7e095c4349
5 changed files with 292 additions and 189 deletions

View File

@ -233,6 +233,19 @@ ExtScript::ScriptData ExtScript::run(const int time)
}
void ExtScript::tryDelete()
{
if (debug) qDebug() << PDEBUG;
for (int i=0; i<dirs.count(); i++) {
QString fileName = dirs[i] + QDir::separator() + name;
if (debug) qDebug() << PDEBUG << ":" << "Remove file" << fileName << QFile::remove(fileName);
if (debug) qDebug() << PDEBUG << ":" << "Remove file" << fileName + QString(".conf") <<
QFile::remove(fileName + QString(".conf"));
}
}
void ExtScript::writeConfiguration()
{
if (debug) qDebug() << PDEBUG;