Core/RefCounted: Remove persistent boolean

Former-commit-id: b5681c26fc30db38b94f9c1ecc9c12ee699af767 [formerly aeebf599245261644fd5fb54fe9f64067a63afc9]
Former-commit-id: f7bcc658c93cc3977ffa91a617b7ca4d463b4aca
This commit is contained in:
Lynix
2016-08-02 12:52:49 +02:00
parent 2674657d02
commit b7a08a6aa7
28 changed files with 4 additions and 110 deletions

View File

@@ -22,7 +22,7 @@ namespace Nz
class NAZARA_CORE_API RefCounted
{
public:
RefCounted(bool persistent = true);
RefCounted();
RefCounted(const RefCounted&) = delete;
RefCounted(RefCounted&&) = default;
virtual ~RefCounted();
@@ -31,17 +31,12 @@ namespace Nz
unsigned int GetReferenceCount() const;
bool IsPersistent() const;
bool RemoveReference() const;
bool SetPersistent(bool persistent = true, bool checkReferenceCount = false);
RefCounted& operator=(const RefCounted&) = delete;
RefCounted& operator=(RefCounted&&) = default;
private:
std::atomic_bool m_persistent;
mutable std::atomic_uint m_referenceCount;
};
}