diff options
Diffstat (limited to 'core/fxcrt/xml/cfx_xmlinstruction.h')
-rw-r--r-- | core/fxcrt/xml/cfx_xmlinstruction.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/core/fxcrt/xml/cfx_xmlinstruction.h b/core/fxcrt/xml/cfx_xmlinstruction.h index 153ef2b625..8962d73ac1 100644 --- a/core/fxcrt/xml/cfx_xmlinstruction.h +++ b/core/fxcrt/xml/cfx_xmlinstruction.h @@ -36,4 +36,10 @@ class CFX_XMLInstruction : public CFX_XMLNode { std::vector<WideString> m_TargetData; }; +inline CFX_XMLInstruction* ToXMLInstruction(CFX_XMLNode* pNode) { + return pNode && pNode->GetType() == FX_XMLNODE_Instruction + ? static_cast<CFX_XMLInstruction*>(pNode) + : nullptr; +} + #endif // CORE_FXCRT_XML_CFX_XMLINSTRUCTION_H_ |