diff --git a/src/apps/haiku-depot/PackageInfo.cpp b/src/apps/haiku-depot/PackageInfo.cpp index 0bd9dbf5d0..ad19760926 100644 --- a/src/apps/haiku-depot/PackageInfo.cpp +++ b/src/apps/haiku-depot/PackageInfo.cpp @@ -450,7 +450,8 @@ PackageInfo::PackageInfo() fScreenshots(), fState(NONE), fDownloadProgress(0.0), - fFlags(0) + fFlags(0), + fSystemDependency(false) { } @@ -472,7 +473,8 @@ PackageInfo::PackageInfo(const BitmapRef& icon, const BString& title, fScreenshots(), fState(NONE), fDownloadProgress(0.0), - fFlags(flags) + fFlags(flags), + fSystemDependency(false) { } @@ -492,7 +494,8 @@ PackageInfo::PackageInfo(const PackageInfo& other) fState(other.fState), fInstallationLocations(other.fInstallationLocations), fDownloadProgress(other.fDownloadProgress), - fFlags(other.fFlags) + fFlags(other.fFlags), + fSystemDependency(other.fSystemDependency) { } @@ -514,6 +517,7 @@ PackageInfo::operator=(const PackageInfo& other) fInstallationLocations = other.fInstallationLocations; fDownloadProgress = other.fDownloadProgress; fFlags = other.fFlags; + fSystemDependency = other.fSystemDependency; return *this; } @@ -533,7 +537,8 @@ PackageInfo::operator==(const PackageInfo& other) const && fScreenshots == other.fScreenshots && fState == other.fState && fFlags == other.fFlags - && fDownloadProgress == other.fDownloadProgress; + && fDownloadProgress == other.fDownloadProgress + && fSystemDependency == other.fSystemDependency; } @@ -558,6 +563,13 @@ PackageInfo::AddCategory(const CategoryRef& category) } +void +PackageInfo::SetSystemDependency(bool isDependency) +{ + fSystemDependency = isDependency; +} + + void PackageInfo::SetState(PackageState state) { diff --git a/src/apps/haiku-depot/PackageInfo.h b/src/apps/haiku-depot/PackageInfo.h index a5e7c45219..a7d007dae0 100644 --- a/src/apps/haiku-depot/PackageInfo.h +++ b/src/apps/haiku-depot/PackageInfo.h @@ -232,6 +232,10 @@ public: { return fFlags; } bool IsSystemPackage() const; + bool IsSystemDependency() const + { return fSystemDependency; } + void SetSystemDependency(bool isDependency); + PackageState State() const { return fState; } void SetState(PackageState state); @@ -283,6 +287,7 @@ private: float fDownloadProgress; PackageListenerList fListeners; int32 fFlags; + bool fSystemDependency; };