From 0ae8e03cc2d310ba0ba19b878ea448f17a577cdb Mon Sep 17 00:00:00 2001 From: Dan Sinclair Date: Thu, 30 Nov 2017 20:50:20 +0000 Subject: Create CXFA_Node::NameToAttributeEnum This CL removes XFA_GetAttributeEnumByName and moves the functionality into CXFA_Node::NameToAttriuteEnum. Change-Id: Id1484103c62bf7728d5406c22fb9d83fc0e032e1 Reviewed-on: https://pdfium-review.googlesource.com/19791 Reviewed-by: Henrique Nakashima Commit-Queue: dsinclair --- xfa/fxfa/parser/cxfa_node.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'xfa/fxfa/parser/cxfa_node.h') diff --git a/xfa/fxfa/parser/cxfa_node.h b/xfa/fxfa/parser/cxfa_node.h index 3d0b3db673..3e05f36fab 100644 --- a/xfa/fxfa/parser/cxfa_node.h +++ b/xfa/fxfa/parser/cxfa_node.h @@ -14,6 +14,7 @@ #include "core/fxcrt/fx_string.h" #include "fxjs/cjx_node.h" +#include "third_party/base/optional.h" #include "xfa/fxfa/parser/cxfa_object.h" class CFX_XMLNode; @@ -62,6 +63,8 @@ class CXFA_Node : public CXFA_Object { #endif // NDEBUG static WideString AttributeEnumToName(XFA_ATTRIBUTEENUM item); + static pdfium::Optional NameToAttributeEnum( + const WideStringView& name); static XFA_Attribute NameToAttribute(const WideStringView& name); static WideString AttributeToName(XFA_Attribute attr); static XFA_Element NameToElement(const WideString& name); -- cgit v1.2.3