From b657e87fa1e25997c8277fa49ed33ff245391f31 Mon Sep 17 00:00:00 2001 From: Dan Sinclair Date: Wed, 24 Jan 2018 20:05:29 +0000 Subject: Cleanup CreateUIChild node creation This CL cleans up some of the code around creating the XML nodes related to the UI widgets. Change-Id: Ib91364439ab039f46e44690e92cc0cb93a8da203 Reviewed-on: https://pdfium-review.googlesource.com/23770 Reviewed-by: Henrique Nakashima Commit-Queue: dsinclair --- xfa/fxfa/parser/cxfa_choicelist.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'xfa/fxfa/parser/cxfa_choicelist.cpp') diff --git a/xfa/fxfa/parser/cxfa_choicelist.cpp b/xfa/fxfa/parser/cxfa_choicelist.cpp index 33f868316f..4bd8387917 100644 --- a/xfa/fxfa/parser/cxfa_choicelist.cpp +++ b/xfa/fxfa/parser/cxfa_choicelist.cpp @@ -42,3 +42,10 @@ CXFA_ChoiceList::CXFA_ChoiceList(CXFA_Document* doc, XFA_PacketType packet) pdfium::MakeUnique(this)) {} CXFA_ChoiceList::~CXFA_ChoiceList() {} + +XFA_Element CXFA_ChoiceList::GetValueNodeType() const { + return JSObject()->GetEnum(XFA_Attribute::Open) == + XFA_AttributeEnum::MultiSelect + ? XFA_Element::ExData + : XFA_Element::Text; +} -- cgit v1.2.3