Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(576)

Unified Diff: xfa/fxfa/parser/xfa_layout_itemlayout.cpp

Issue 2093663002: Cleanup some variable namings. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: fix headers Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « xfa/fxfa/parser/xfa_document_serialize.cpp ('k') | xfa/fxfa/parser/xfa_layout_pagemgr_new.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fxfa/parser/xfa_layout_itemlayout.cpp
diff --git a/xfa/fxfa/parser/xfa_layout_itemlayout.cpp b/xfa/fxfa/parser/xfa_layout_itemlayout.cpp
index f5857178da37b2104fddd420bc697250df49a1f4..5b33e70c36554a8a34895d0593c7971c6bf7d360 100644
--- a/xfa/fxfa/parser/xfa_layout_itemlayout.cpp
+++ b/xfa/fxfa/parser/xfa_layout_itemlayout.cpp
@@ -901,29 +901,29 @@ static inline void XFA_ItemLayoutProcessor_CalculateContainerSpecfiedSize(
fContainerHeight = 0;
bContainerWidthAutoSize = TRUE;
bContainerHeightAutoSize = TRUE;
- XFA_Element eClassID = pFormNode->GetElementType();
+ XFA_Element eType = pFormNode->GetElementType();
CXFA_Measurement mTmpValue;
- if (bContainerWidthAutoSize && (eClassID == XFA_Element::Subform ||
- eClassID == XFA_Element::ExclGroup) &&
+ if (bContainerWidthAutoSize &&
+ (eType == XFA_Element::Subform || eType == XFA_Element::ExclGroup) &&
pFormNode->TryMeasure(XFA_ATTRIBUTE_W, mTmpValue, FALSE) &&
mTmpValue.GetValue() > XFA_LAYOUT_FLOAT_PERCISION) {
fContainerWidth = mTmpValue.ToUnit(XFA_UNIT_Pt);
bContainerWidthAutoSize = FALSE;
}
- if (bContainerHeightAutoSize && (eClassID == XFA_Element::Subform ||
- eClassID == XFA_Element::ExclGroup) &&
+ if (bContainerHeightAutoSize &&
+ (eType == XFA_Element::Subform || eType == XFA_Element::ExclGroup) &&
pFormNode->TryMeasure(XFA_ATTRIBUTE_H, mTmpValue, FALSE) &&
mTmpValue.GetValue() > XFA_LAYOUT_FLOAT_PERCISION) {
fContainerHeight = mTmpValue.ToUnit(XFA_UNIT_Pt);
bContainerHeightAutoSize = FALSE;
}
- if (bContainerWidthAutoSize && eClassID == XFA_Element::Subform &&
+ if (bContainerWidthAutoSize && eType == XFA_Element::Subform &&
pFormNode->TryMeasure(XFA_ATTRIBUTE_MaxW, mTmpValue, FALSE) &&
mTmpValue.GetValue() > XFA_LAYOUT_FLOAT_PERCISION) {
fContainerWidth = mTmpValue.ToUnit(XFA_UNIT_Pt);
bContainerWidthAutoSize = FALSE;
}
- if (bContainerHeightAutoSize && eClassID == XFA_Element::Subform &&
+ if (bContainerHeightAutoSize && eType == XFA_Element::Subform &&
pFormNode->TryMeasure(XFA_ATTRIBUTE_MaxH, mTmpValue, FALSE) &&
mTmpValue.GetValue() > XFA_LAYOUT_FLOAT_PERCISION) {
fContainerHeight = mTmpValue.ToUnit(XFA_UNIT_Pt);
@@ -1218,8 +1218,7 @@ static inline void XFA_ItemLayoutProcessor_UpdateWidgetSize(
FX_FLOAT& fHeight) {
CXFA_Node* pNode = pLayoutItem->m_pFormNode;
ASSERT(pNode);
- XFA_Element eClassID = pNode->GetElementType();
- switch (eClassID) {
+ switch (pNode->GetElementType()) {
case XFA_Element::Subform:
case XFA_Element::Area:
case XFA_Element::ExclGroup:
@@ -2911,8 +2910,7 @@ XFA_ItemLayoutProcessorResult CXFA_ItemLayoutProcessor::DoLayout(
FX_FLOAT fHeightLimit,
FX_FLOAT fRealHeight,
CXFA_LayoutContext* pContext) {
- XFA_Element eClassID = m_pFormNode->GetElementType();
- switch (eClassID) {
+ switch (m_pFormNode->GetElementType()) {
case XFA_Element::Subform:
case XFA_Element::Area:
case XFA_Element::ExclGroup:
« no previous file with comments | « xfa/fxfa/parser/xfa_document_serialize.cpp ('k') | xfa/fxfa/parser/xfa_layout_pagemgr_new.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698