mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-12-24 09:58:46 +00:00
Changed: QDir.cd already checks if directory exists, see #279
--HG-- branch : develop
This commit is contained in:
parent
400c17826e
commit
508b5fdd24
2 changed files with 4 additions and 4 deletions
|
@ -679,7 +679,7 @@ bool CConfigFile::foundTemporaryFiles(const QString &directory) const
|
|||
// directory doesn't exist
|
||||
if (!dir.exists()) return false;
|
||||
|
||||
if (!dir.cd("data") && dir.exists()) return false;
|
||||
if (!dir.cd("data")) return false;
|
||||
|
||||
QStringList filter;
|
||||
filter << "*.string_cache";
|
||||
|
@ -695,7 +695,7 @@ bool CConfigFile::foundTemporaryFiles(const QString &directory) const
|
|||
if (!dir.entryList(filter, QDir::Files).isEmpty()) return true;
|
||||
|
||||
// fonts directory is not needed anymore
|
||||
if (dir.exists("fonts.bnp") && dir.cd("fonts") && dir.exists()) return true;
|
||||
if (dir.exists("fonts.bnp") && !dir.cd("fonts")) return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -46,7 +46,7 @@ bool CFilesCleaner::exec()
|
|||
// directory doesn't exist
|
||||
if (!dir.exists()) return false;
|
||||
|
||||
if (!dir.cd("data") && dir.exists()) return false;
|
||||
if (!dir.cd("data")) return false;
|
||||
|
||||
QStringList filter;
|
||||
filter << "*.string_cache";
|
||||
|
@ -79,7 +79,7 @@ bool CFilesCleaner::exec()
|
|||
}
|
||||
|
||||
// fonts directory is not needed anymore if fonts.bnp exists
|
||||
if (dir.exists("fonts.bnp") && dir.cd("fonts") && dir.exists())
|
||||
if (dir.exists("fonts.bnp") && dir.cd("fonts"))
|
||||
{
|
||||
dir.removeRecursively();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue