Files
core/ASCOfficePPTXFile/PPTXFormat/Logic/EffectStyle.cpp

61 lines
1.1 KiB
C++

#include "EffectStyle.h"
namespace PPTX
{
namespace Logic
{
EffectStyle::EffectStyle()
{
}
EffectStyle::~EffectStyle()
{
}
EffectStyle::EffectStyle(XmlUtils::CXmlNode& node)
{
fromXML(node);
}
const EffectStyle& EffectStyle::operator =(XmlUtils::CXmlNode& node)
{
fromXML(node);
return *this;
}
void EffectStyle::fromXML(XmlUtils::CXmlNode& node)
{
EffectList.GetEffectListFrom(node);
scene3d = node.ReadNode(_T("a:scene3d"));
sp3d = node.ReadNode(_T("a:sp3d"));
FillParentPointersForChilds();
}
CString EffectStyle::toXML() const
{
XmlUtils::CNodeValue oValue;
oValue.Write(EffectList);
oValue.WriteNullable(scene3d);
oValue.WriteNullable(sp3d);
return XmlUtils::CreateNode(_T("a:effectStyle"), oValue);
}
void EffectStyle::FillParentPointersForChilds()
{
EffectList.SetParentPointer(this);
if(scene3d.IsInit())
scene3d->SetParentPointer(this);
if(sp3d.IsInit())
sp3d->SetParentPointer(this);
}
} // namespace Logic
} // namespace PPTX