Caf: Small Adjustments

This commit is contained in:
Jacob Støren 2016-06-19 16:15:39 +02:00
parent 9f54d74c7f
commit f2da9bfea1
3 changed files with 3 additions and 2 deletions

View File

@ -5,7 +5,7 @@ namespace caf
{
//==================================================================================================
/// Implementation of PdmPointersField<>
/// Implementation of PdmChildArrayField<>
//==================================================================================================

View File

@ -37,7 +37,7 @@ class PdmPtrField <DataType*> : public PdmFieldHandle
public:
typedef PdmPointer<DataType> FieldDataType;
PdmPtrField() { m_referenceString = ""; m_isResolved = false; }
PdmPtrField() : m_isResolved(false) { }
explicit PdmPtrField(const DataTypePtr& fieldValue);
virtual ~PdmPtrField();

View File

@ -7,6 +7,7 @@ namespace caf
template<typename DataType >
caf::PdmPtrField<DataType*>::PdmPtrField(const DataTypePtr& fieldValue)
{
m_isResolved = true;
m_fieldValue = fieldValue;
if (m_fieldValue != NULL) m_fieldValue->addReferencingPtrField(this);
}