mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-15 22:19:54 +00:00
25 lines
523 B
C++
25 lines
523 B
C++
#include "referenceinterface.hpp"
|
|
|
|
namespace MWGui
|
|
{
|
|
ReferenceInterface::ReferenceInterface()
|
|
{
|
|
}
|
|
|
|
ReferenceInterface::~ReferenceInterface()
|
|
{
|
|
}
|
|
|
|
void ReferenceInterface::checkReferenceAvailable()
|
|
{
|
|
// check if count of the reference has become 0
|
|
if (!mPtr.isEmpty() && mPtr.getRefData().getCount() == 0)
|
|
{
|
|
if (!mPtr.isEmpty())
|
|
{
|
|
mPtr = MWWorld::Ptr();
|
|
onReferenceUnavailable();
|
|
}
|
|
}
|
|
}
|
|
}
|