summaryrefslogtreecommitdiffstats
path: root/heimdall-frontend/source/PackageData.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'heimdall-frontend/source/PackageData.cpp')
-rw-r--r--heimdall-frontend/source/PackageData.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/heimdall-frontend/source/PackageData.cpp b/heimdall-frontend/source/PackageData.cpp
index c17917b..42718bf 100644
--- a/heimdall-frontend/source/PackageData.cpp
+++ b/heimdall-frontend/source/PackageData.cpp
@@ -38,17 +38,17 @@ PackageData::PackageData()
PackageData::~PackageData()
{
- Clear(true);
+ Clear();
}
-void PackageData::Clear(bool deletePackageDirectory)
+void PackageData::Clear(void)
{
- if (deletePackageDirectory)
+ for (QDir& dir : ownedDirectories)
{
- packageDirectory.removeRecursively();
+ dir.removeRecursively();
}
- packageDirectory.setPath(QString());
+ ownedDirectories.clear();
firmwareInfo.Clear();
filePaths.clear();
}
@@ -71,7 +71,7 @@ bool PackageData::ReadFirmwareInfo(const QString& path)
bool PackageData::IsCleared(void) const
{
- return (packageDirectory.path().length() == 0
+ return (ownedDirectories.length() == 0
&& firmwareInfo.IsCleared()
&& filePaths.isEmpty());
}