HaikuDepot: Add PackageInfo flag for system dependencies.
This commit is contained in:
@@ -450,7 +450,8 @@ PackageInfo::PackageInfo()
|
|||||||
fScreenshots(),
|
fScreenshots(),
|
||||||
fState(NONE),
|
fState(NONE),
|
||||||
fDownloadProgress(0.0),
|
fDownloadProgress(0.0),
|
||||||
fFlags(0)
|
fFlags(0),
|
||||||
|
fSystemDependency(false)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -472,7 +473,8 @@ PackageInfo::PackageInfo(const BitmapRef& icon, const BString& title,
|
|||||||
fScreenshots(),
|
fScreenshots(),
|
||||||
fState(NONE),
|
fState(NONE),
|
||||||
fDownloadProgress(0.0),
|
fDownloadProgress(0.0),
|
||||||
fFlags(flags)
|
fFlags(flags),
|
||||||
|
fSystemDependency(false)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -492,7 +494,8 @@ PackageInfo::PackageInfo(const PackageInfo& other)
|
|||||||
fState(other.fState),
|
fState(other.fState),
|
||||||
fInstallationLocations(other.fInstallationLocations),
|
fInstallationLocations(other.fInstallationLocations),
|
||||||
fDownloadProgress(other.fDownloadProgress),
|
fDownloadProgress(other.fDownloadProgress),
|
||||||
fFlags(other.fFlags)
|
fFlags(other.fFlags),
|
||||||
|
fSystemDependency(other.fSystemDependency)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -514,6 +517,7 @@ PackageInfo::operator=(const PackageInfo& other)
|
|||||||
fInstallationLocations = other.fInstallationLocations;
|
fInstallationLocations = other.fInstallationLocations;
|
||||||
fDownloadProgress = other.fDownloadProgress;
|
fDownloadProgress = other.fDownloadProgress;
|
||||||
fFlags = other.fFlags;
|
fFlags = other.fFlags;
|
||||||
|
fSystemDependency = other.fSystemDependency;
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -533,7 +537,8 @@ PackageInfo::operator==(const PackageInfo& other) const
|
|||||||
&& fScreenshots == other.fScreenshots
|
&& fScreenshots == other.fScreenshots
|
||||||
&& fState == other.fState
|
&& fState == other.fState
|
||||||
&& fFlags == other.fFlags
|
&& 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
|
void
|
||||||
PackageInfo::SetState(PackageState state)
|
PackageInfo::SetState(PackageState state)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -232,6 +232,10 @@ public:
|
|||||||
{ return fFlags; }
|
{ return fFlags; }
|
||||||
bool IsSystemPackage() const;
|
bool IsSystemPackage() const;
|
||||||
|
|
||||||
|
bool IsSystemDependency() const
|
||||||
|
{ return fSystemDependency; }
|
||||||
|
void SetSystemDependency(bool isDependency);
|
||||||
|
|
||||||
PackageState State() const
|
PackageState State() const
|
||||||
{ return fState; }
|
{ return fState; }
|
||||||
void SetState(PackageState state);
|
void SetState(PackageState state);
|
||||||
@@ -283,6 +287,7 @@ private:
|
|||||||
float fDownloadProgress;
|
float fDownloadProgress;
|
||||||
PackageListenerList fListeners;
|
PackageListenerList fListeners;
|
||||||
int32 fFlags;
|
int32 fFlags;
|
||||||
|
bool fSystemDependency;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user