Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
cxfa_treelist.cpp
Go to the documentation of this file.
1
// Copyright 2017 The PDFium Authors
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6
7
#
include
"xfa/fxfa/parser/cxfa_treelist.h"
8
9
#
include
"core/fxcrt/fx_extension.h"
10
#
include
"fxjs/xfa/cjx_treelist.h"
11
#
include
"xfa/fxfa/parser/cxfa_document.h"
12
#
include
"xfa/fxfa/parser/cxfa_node.h"
13
14
CXFA_TreeList
::
CXFA_TreeList
(CXFA_Document* doc)
15
:
CXFA_List
(
doc
,
16
XFA_ObjectType
::
TreeList
,
17
XFA_Element
::
TreeList
,
18
cppgc
::
MakeGarbageCollected
<
CJX_TreeList
>(
19
doc
->
GetHeap
()->
GetAllocationHandle
(),
20
this
)) {}
21
22
CXFA_TreeList
::~
CXFA_TreeList
() =
default
;
23
24
CXFA_Node
*
CXFA_TreeList
::
NamedItem
(WideStringView wsName) {
25
uint32_t dwHashCode = FX_HashCode_GetW(wsName);
26
size_t count = GetLength();
27
for
(size_t i = 0; i < count; i++) {
28
CXFA_Node
* ret = Item(i);
29
if
(dwHashCode == ret
->
GetNameHash
(
)
)
30
return
ret;
31
}
32
return
nullptr
;
33
}
CXFA_Node
Definition
cxfa_node.h:93
CXFA_Node::GetNameHash
uint32_t GetNameHash() const
Definition
cxfa_node.h:190
CXFA_TreeList
Definition
cxfa_treelist.h:15
CXFA_TreeList::~CXFA_TreeList
~CXFA_TreeList() override
CXFA_TreeList::NamedItem
CXFA_Node * NamedItem(WideStringView wsName)
Definition
cxfa_treelist.cpp:24
CXFA_TreeList::CXFA_TreeList
CXFA_TreeList(CXFA_Document *pDocument)
Definition
cxfa_treelist.cpp:14
qtwebengine
src
3rdparty
chromium
third_party
pdfium
xfa
fxfa
parser
cxfa_treelist.cpp
Generated on Sat Sep 21 2024 01:05:04 for Qt by
1.12.0