diff options
author | weili <weili@chromium.org> | 2016-05-20 15:38:29 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-05-20 15:38:30 -0700 |
commit | 038aa531bcf1a76764d3cef46fd9b8e08b166dae (patch) | |
tree | d1ef7d15ff37e4c98d1d7522b225755ba99bc330 /xfa/fxfa | |
parent | dc3ccdfb49c4d533d524d2084a7ebe5117f35934 (diff) | |
download | pdfium-038aa531bcf1a76764d3cef46fd9b8e08b166dae.tar.xz |
Clean up XFA code which causes warnings
This is part of efforts to bring XFA to chromium_code standard.
The warnings are from unreachable code, or using potentially
uninitialized variables, or using assignment within a condition.
This change list only contains easy to fix cases. More cleanups
will follow.
BUG=pdfium:29
Review-Url: https://codereview.chromium.org/1998873002
Diffstat (limited to 'xfa/fxfa')
-rw-r--r-- | xfa/fxfa/app/xfa_ffdocview.cpp | 4 | ||||
-rw-r--r-- | xfa/fxfa/app/xfa_ffnotify.cpp | 8 | ||||
-rw-r--r-- | xfa/fxfa/app/xfa_ffwidget.cpp | 65 | ||||
-rw-r--r-- | xfa/fxfa/app/xfa_ffwidgetacc.cpp | 2 | ||||
-rw-r--r-- | xfa/fxfa/fm2js/xfa_fm2jscontext.cpp | 30 | ||||
-rw-r--r-- | xfa/fxfa/parser/xfa_basic_imp.cpp | 1 | ||||
-rw-r--r-- | xfa/fxfa/parser/xfa_document_datamerger_imp.cpp | 4 | ||||
-rw-r--r-- | xfa/fxfa/parser/xfa_localemgr.cpp | 5 | ||||
-rw-r--r-- | xfa/fxfa/parser/xfa_object_imp.cpp | 2 | ||||
-rw-r--r-- | xfa/fxfa/parser/xfa_parser_imp.cpp | 1 | ||||
-rw-r--r-- | xfa/fxfa/parser/xfa_utils.h | 8 | ||||
-rw-r--r-- | xfa/fxfa/parser/xfa_utils_imp.cpp | 2 |
12 files changed, 69 insertions, 63 deletions
diff --git a/xfa/fxfa/app/xfa_ffdocview.cpp b/xfa/fxfa/app/xfa_ffdocview.cpp index d8543fa511..131e8cd82f 100644 --- a/xfa/fxfa/app/xfa_ffdocview.cpp +++ b/xfa/fxfa/app/xfa_ffdocview.cpp @@ -874,9 +874,9 @@ CXFA_WidgetAcc* CXFA_WidgetAccIterator::MoveToNext() { CXFA_Node* pItem = m_pCurWidgetAcc ? m_ContentIterator.MoveToNext() : m_ContentIterator.GetCurrent(); while (pItem) { - if ((m_pCurWidgetAcc = (CXFA_WidgetAcc*)pItem->GetWidgetData())) { + m_pCurWidgetAcc = (CXFA_WidgetAcc*)pItem->GetWidgetData(); + if (m_pCurWidgetAcc) return m_pCurWidgetAcc; - } pItem = m_ContentIterator.MoveToNext(); } return NULL; diff --git a/xfa/fxfa/app/xfa_ffnotify.cpp b/xfa/fxfa/app/xfa_ffnotify.cpp index 4d7d4799f2..e8fb4dd1dc 100644 --- a/xfa/fxfa/app/xfa_ffnotify.cpp +++ b/xfa/fxfa/app/xfa_ffnotify.cpp @@ -56,7 +56,7 @@ void CXFA_FFNotify::OnWidgetListItemAdded(CXFA_WidgetData* pSender, return; CXFA_FFWidget* pWidget = nullptr; - while ((pWidget = pWidgetAcc->GetNextWidget(pWidget))) { + while ((pWidget = pWidgetAcc->GetNextWidget(pWidget)) != nullptr) { if (pWidget->IsLoaded()) { if (pWidgetAcc->IsListBox()) { static_cast<CXFA_FFListBox*>(pWidget)->InsertItem(pLabel, iIndex); @@ -74,7 +74,7 @@ void CXFA_FFNotify::OnWidgetListItemRemoved(CXFA_WidgetData* pSender, return; CXFA_FFWidget* pWidget = nullptr; - while ((pWidget = pWidgetAcc->GetNextWidget(pWidget))) { + while ((pWidget = pWidgetAcc->GetNextWidget(pWidget)) != nullptr) { if (pWidget->IsLoaded()) { if (pWidgetAcc->IsListBox()) { static_cast<CXFA_FFListBox*>(pWidget)->DeleteItem(iIndex); @@ -360,7 +360,7 @@ void CXFA_FFNotify::OnValueChanging(CXFA_Node* pSender, XFA_ATTRIBUTE eAttr) { return; CXFA_FFWidget* pWidget = nullptr; - while ((pWidget = pWidgetAcc->GetNextWidget(pWidget))) { + while ((pWidget = pWidgetAcc->GetNextWidget(pWidget)) != nullptr) { if (pWidget->IsLoaded()) pWidget->AddInvalidateRect(); } @@ -422,7 +422,7 @@ void CXFA_FFNotify::OnValueChanged(CXFA_Node* pSender, } } CXFA_FFWidget* pWidget = nullptr; - while ((pWidget = pWidgetAcc->GetNextWidget(pWidget))) { + while ((pWidget = pWidgetAcc->GetNextWidget(pWidget)) != nullptr) { if (!pWidget->IsLoaded()) continue; diff --git a/xfa/fxfa/app/xfa_ffwidget.cpp b/xfa/fxfa/app/xfa_ffwidget.cpp index 3af84a6bbe..8ce583a782 100644 --- a/xfa/fxfa/app/xfa_ffwidget.cpp +++ b/xfa/fxfa/app/xfa_ffwidget.cpp @@ -270,12 +270,13 @@ void CXFA_FFWidget::Rotate2Normal(FX_FLOAT& fx, FX_FLOAT& fy) { } static void XFA_GetMatrix(CFX_Matrix& m, int32_t iRotate, - int32_t at, + XFA_ATTRIBUTEENUM at, const CFX_RectF& rt) { if (!iRotate) { return; } - FX_FLOAT fAnchorX, fAnchorY; + FX_FLOAT fAnchorX = 0; + FX_FLOAT fAnchorY = 0; switch (at) { case XFA_ATTRIBUTEENUM_TopLeft: fAnchorX = rt.left, fAnchorY = rt.top; @@ -305,6 +306,8 @@ static void XFA_GetMatrix(CFX_Matrix& m, case XFA_ATTRIBUTEENUM_BottomRight: fAnchorX = rt.right(), fAnchorY = rt.bottom(); break; + default: + break; } switch (iRotate) { case 90: @@ -1157,20 +1160,15 @@ static void XFA_BOX_GetPath(CXFA_Box box, FX_BOOL bStart, FX_BOOL bCorner) { ASSERT(nIndex >= 0 && nIndex < 8); - FX_BOOL bInverted, bRound; - FX_FLOAT fRadius1, fRadius2, sx, sy, vx, vy, nx, ny, offsetY, offsetX, - offsetEX, offsetEY; - CFX_PointF cpStart, cp, cp1, cp2; - CFX_RectF rtRadius; int32_t n = (nIndex & 1) ? nIndex - 1 : nIndex; CXFA_Corner corner1(strokes[n].GetNode()); CXFA_Corner corner2(strokes[(n + 2) % 8].GetNode()); - fRadius1 = bCorner ? corner1.GetRadius() : 0; - fRadius2 = bCorner ? corner2.GetRadius() : 0; - bInverted = corner1.IsInverted(); - offsetY = 0.0f; - offsetX = 0.0f; - bRound = corner1.GetJoinType() == XFA_ATTRIBUTEENUM_Round; + FX_FLOAT fRadius1 = bCorner ? corner1.GetRadius() : 0.0f; + FX_FLOAT fRadius2 = bCorner ? corner2.GetRadius() : 0.0f; + FX_BOOL bInverted = corner1.IsInverted(); + FX_FLOAT offsetY = 0.0f; + FX_FLOAT offsetX = 0.0f; + FX_BOOL bRound = corner1.GetJoinType() == XFA_ATTRIBUTEENUM_Round; FX_FLOAT halfAfter = 0.0f; FX_FLOAT halfBefore = 0.0f; CXFA_Stroke stroke = strokes[nIndex]; @@ -1189,12 +1187,21 @@ static void XFA_BOX_GetPath(CXFA_Box box, CXFA_Stroke edgeBefore = strokes[(nIndex + 8 - 2) % 8]; CXFA_Stroke edgeAfter = strokes[(nIndex + 2) % 8]; if (!bRound && !bInverted) { - { halfBefore = edgeBefore.GetThickness() / 2; } - { halfAfter = edgeAfter.GetThickness() / 2; } + halfBefore = edgeBefore.GetThickness() / 2; + halfAfter = edgeAfter.GetThickness() / 2; } } - offsetEX = 0.0f; - offsetEY = 0.0f; + FX_FLOAT offsetEX = 0.0f; + FX_FLOAT offsetEY = 0.0f; + FX_FLOAT sx = 0.0f; + FX_FLOAT sy = 0.0f; + FX_FLOAT vx = 1.0f; + FX_FLOAT vy = 1.0f; + FX_FLOAT nx = 1.0f; + FX_FLOAT ny = 1.0f; + CFX_PointF cpStart; + CFX_PointF cp1; + CFX_PointF cp2; if (bRound) { sy = FX_PI / 2; } @@ -1291,6 +1298,7 @@ static void XFA_BOX_GetPath(CXFA_Box box, if (bInverted) { sy *= -1; } + CFX_RectF rtRadius; rtRadius.Set(cp1.x + offsetX * 2, cp1.y + offsetY * 2, fRadius1 * 2 * vx - offsetX * 2, fRadius1 * 2 * vy - offsetY * 2); @@ -1301,6 +1309,7 @@ static void XFA_BOX_GetPath(CXFA_Box box, path.ArcTo(rtRadius.left, rtRadius.top, rtRadius.width, rtRadius.height, sx, sy); } else { + CFX_PointF cp; if (bInverted) { cp.x = cp1.x + fRadius1 * vx, cp.y = cp1.y + fRadius1 * vy; } else { @@ -1369,17 +1378,21 @@ static void XFA_BOX_GetFillPath(CXFA_Box box, rtWidget.height); return; } - FX_BOOL bInverted, bRound; - FX_FLOAT fRadius1, fRadius2, sx, sy, vx, vy, nx, ny; - CFX_PointF cp, cp1, cp2; - CFX_RectF rtRadius; + for (int32_t i = 0; i < 8; i += 2) { + FX_FLOAT sx = 0.0f; + FX_FLOAT sy = 0.0f; + FX_FLOAT vx = 1.0f; + FX_FLOAT vy = 1.0f; + FX_FLOAT nx = 1.0f; + FX_FLOAT ny = 1.0f; + CFX_PointF cp1, cp2; CXFA_Corner corner1(strokes[i].GetNode()); CXFA_Corner corner2(strokes[(i + 2) % 8].GetNode()); - fRadius1 = corner1.GetRadius(); - fRadius2 = corner2.GetRadius(); - bInverted = corner1.IsInverted(); - bRound = corner1.GetJoinType() == XFA_ATTRIBUTEENUM_Round; + FX_FLOAT fRadius1 = corner1.GetRadius(); + FX_FLOAT fRadius2 = corner2.GetRadius(); + FX_BOOL bInverted = corner1.IsInverted(); + FX_BOOL bRound = corner1.GetJoinType() == XFA_ATTRIBUTEENUM_Round; if (bRound) { sy = FX_PI / 2; } @@ -1439,6 +1452,7 @@ static void XFA_BOX_GetFillPath(CXFA_Box box, if (bInverted) { sy *= -1; } + CFX_RectF rtRadius; rtRadius.Set(cp1.x, cp1.y, fRadius1 * 2 * vx, fRadius1 * 2 * vy); rtRadius.Normalize(); if (bInverted) { @@ -1447,6 +1461,7 @@ static void XFA_BOX_GetFillPath(CXFA_Box box, fillPath.ArcTo(rtRadius.left, rtRadius.top, rtRadius.width, rtRadius.height, sx, sy); } else { + CFX_PointF cp; if (bInverted) { cp.x = cp1.x + fRadius1 * vx, cp.y = cp1.y + fRadius1 * vy; } else { diff --git a/xfa/fxfa/app/xfa_ffwidgetacc.cpp b/xfa/fxfa/app/xfa_ffwidgetacc.cpp index 08c52de79a..2c84a7f9b7 100644 --- a/xfa/fxfa/app/xfa_ffwidgetacc.cpp +++ b/xfa/fxfa/app/xfa_ffwidgetacc.cpp @@ -713,7 +713,7 @@ CXFA_FFWidget* CXFA_WidgetAcc::GetNextWidget(CXFA_FFWidget* pWidget) { } void CXFA_WidgetAcc::UpdateUIDisplay(CXFA_FFWidget* pExcept) { CXFA_FFWidget* pWidget = NULL; - while ((pWidget = GetNextWidget(pWidget))) { + while ((pWidget = GetNextWidget(pWidget)) != nullptr) { if (pWidget == pExcept || !pWidget->IsLoaded() || (GetUIType() != XFA_ELEMENT_CheckButton && pWidget->IsFocused())) { continue; diff --git a/xfa/fxfa/fm2js/xfa_fm2jscontext.cpp b/xfa/fxfa/fm2js/xfa_fm2jscontext.cpp index 96ebbfa1e9..4813eb1a63 100644 --- a/xfa/fxfa/fm2js/xfa_fm2jscontext.cpp +++ b/xfa/fxfa/fm2js/xfa_fm2jscontext.cpp @@ -1291,7 +1291,7 @@ void CXFA_FM2JSContext::Num2Date(FXJSE_HOBJECT hThis, int32_t argc = args.GetLength(); if ((argc > 0) && (argc < 4)) { FX_BOOL bFlags = FALSE; - int32_t dDate; + int32_t dDate = 0; CFX_ByteString formatString; CFX_ByteString localString; FXJSE_HVALUE dateValue = GetSimpleHValue(hThis, args, 0); @@ -1446,7 +1446,7 @@ void CXFA_FM2JSContext::Num2GMTime(FXJSE_HOBJECT hThis, int32_t argc = args.GetLength(); if ((argc > 0) && (argc < 4)) { FX_BOOL bFlags = FALSE; - int32_t iTime; + int32_t iTime = 0; CFX_ByteString formatString; CFX_ByteString localString; FXJSE_HVALUE timeValue = GetSimpleHValue(hThis, args, 0); @@ -1508,7 +1508,7 @@ void CXFA_FM2JSContext::Num2Time(FXJSE_HOBJECT hThis, int32_t argc = args.GetLength(); if ((argc > 0) && (argc < 4)) { FX_BOOL bFlags = FALSE; - FX_FLOAT fTime; + FX_FLOAT fTime = 0.0f; CFX_ByteString formatString; CFX_ByteString localString; FXJSE_HVALUE timeValue = GetSimpleHValue(hThis, args, 0); @@ -4860,7 +4860,7 @@ void CXFA_FM2JSContext::Str(FXJSE_HOBJECT hThis, int32_t argc = args.GetLength(); if ((argc > 0) && (argc < 4)) { FX_BOOL bFlags = FALSE; - FX_FLOAT fNumber; + FX_FLOAT fNumber = 0.0f; int32_t iWidth = 10; int32_t iPrecision = 0; FXJSE_HVALUE numberValue = GetSimpleHValue(hThis, args, 0); @@ -5171,7 +5171,7 @@ void CXFA_FM2JSContext::WordNum(FXJSE_HOBJECT hThis, int32_t argc = args.GetLength(); if ((argc > 0) && (argc < 4)) { FX_BOOL bFlags = FALSE; - FX_FLOAT fNumber; + FX_FLOAT fNumber = 0.0f; int32_t iIdentifier = 0; CFX_ByteString localeString; FXJSE_HVALUE numberValue = GetSimpleHValue(hThis, args, 0); @@ -5477,14 +5477,12 @@ void CXFA_FM2JSContext::Post(FXJSE_HOBJECT hThis, CFX_ByteString bsContentType; CFX_ByteString bsEncode; CFX_ByteString bsHeader; - FXJSE_HVALUE argOne; - FXJSE_HVALUE argTwo; - FXJSE_HVALUE argThree; - FXJSE_HVALUE argFour; - FXJSE_HVALUE argFive; - argOne = GetSimpleHValue(hThis, args, 0); + FXJSE_HVALUE argThree = nullptr; + FXJSE_HVALUE argFour = nullptr; + FXJSE_HVALUE argFive = nullptr; + FXJSE_HVALUE argOne = GetSimpleHValue(hThis, args, 0); HValueToUTF8String(argOne, bsURL); - argTwo = GetSimpleHValue(hThis, args, 1); + FXJSE_HVALUE argTwo = GetSimpleHValue(hThis, args, 1); HValueToUTF8String(argTwo, bsData); if (argc > 2) { argThree = GetSimpleHValue(hThis, args, 2); @@ -5548,12 +5546,10 @@ void CXFA_FM2JSContext::Put(FXJSE_HOBJECT hThis, CFX_ByteString bsURL; CFX_ByteString bsData; CFX_ByteString bsEncode; - FXJSE_HVALUE argOne; - FXJSE_HVALUE argTwo; - FXJSE_HVALUE argThree; - argOne = GetSimpleHValue(hThis, args, 0); + FXJSE_HVALUE argThree = nullptr; + FXJSE_HVALUE argOne = GetSimpleHValue(hThis, args, 0); HValueToUTF8String(argOne, bsURL); - argTwo = GetSimpleHValue(hThis, args, 1); + FXJSE_HVALUE argTwo = GetSimpleHValue(hThis, args, 1); HValueToUTF8String(argTwo, bsData); if (argc > 2) { argThree = GetSimpleHValue(hThis, args, 2); diff --git a/xfa/fxfa/parser/xfa_basic_imp.cpp b/xfa/fxfa/parser/xfa_basic_imp.cpp index 728ecfc319..759d530439 100644 --- a/xfa/fxfa/parser/xfa_basic_imp.cpp +++ b/xfa/fxfa/parser/xfa_basic_imp.cpp @@ -488,7 +488,6 @@ FX_BOOL CXFA_Measurement::ToUnit(XFA_UNIT eUnit, FX_FLOAT& fValue) const { fValue = 0; return FALSE; } - return FALSE; } XFA_UNIT CXFA_Measurement::GetUnit(const CFX_WideStringC& wsUnit) { if (wsUnit == FX_WSTRC(L"mm")) { diff --git a/xfa/fxfa/parser/xfa_document_datamerger_imp.cpp b/xfa/fxfa/parser/xfa_document_datamerger_imp.cpp index 41a0acd70b..5bd8f08970 100644 --- a/xfa/fxfa/parser/xfa_document_datamerger_imp.cpp +++ b/xfa/fxfa/parser/xfa_document_datamerger_imp.cpp @@ -886,13 +886,13 @@ static CXFA_Node* XFA_DataMerge_CopyContainer_SubformSet( pTemplateChild, TRUE); } else if (pTemplateChild->GetObjectType() == XFA_OBJECTTYPE_ContainerNode) { - CXFA_Node* pDataMatch; bSelfMatch = FALSE; eBindMatch = XFA_ATTRIBUTEENUM_None; + CXFA_Node* pDataMatch; if (eRelation != XFA_ATTRIBUTEENUM_Ordered && (pDataMatch = XFA_DataMerge_FindMatchingDataNode( pDocument, pTemplateChild, pDataScope, bAccessedDataDOM, - FALSE, NULL, bSelfMatch, eBindMatch))) { + FALSE, NULL, bSelfMatch, eBindMatch)) != nullptr) { XFA_DataMerge_RecurseRecord sNewRecord = {pTemplateChild, pDataMatch}; if (bSelfMatch) { diff --git a/xfa/fxfa/parser/xfa_localemgr.cpp b/xfa/fxfa/parser/xfa_localemgr.cpp index 0982537b15..83c7cf025d 100644 --- a/xfa/fxfa/parser/xfa_localemgr.cpp +++ b/xfa/fxfa/parser/xfa_localemgr.cpp @@ -1123,9 +1123,8 @@ static uint16_t XFA_GetLanguage(CFX_WideString wsLanguage) { CXFA_LocaleMgr::CXFA_LocaleMgr(CXFA_Node* pLocaleSet, CFX_WideString wsDeflcid) : m_dwLocaleFlags(0x00) { m_dwDeflcid = XFA_GetLanguage(wsDeflcid); - CXFA_Node* pNodeLocale = NULL; - if (pLocaleSet && - (pNodeLocale = pLocaleSet->GetNodeItem(XFA_NODEITEM_FirstChild))) { + if (pLocaleSet) { + CXFA_Node* pNodeLocale = pLocaleSet->GetNodeItem(XFA_NODEITEM_FirstChild); while (pNodeLocale) { m_LocaleArray.Add(new CXFA_NodeLocale(pNodeLocale)); pNodeLocale = pNodeLocale->GetNodeItem(XFA_NODEITEM_NextSibling); diff --git a/xfa/fxfa/parser/xfa_object_imp.cpp b/xfa/fxfa/parser/xfa_object_imp.cpp index 0fbde1f160..6a6303e64e 100644 --- a/xfa/fxfa/parser/xfa_object_imp.cpp +++ b/xfa/fxfa/parser/xfa_object_imp.cpp @@ -4504,7 +4504,7 @@ CXFA_Node* CXFA_Node::GetProperty(int32_t index, } CXFA_Document* pFactory = m_pDocument->GetParser()->GetFactory(); const XFA_PACKETINFO* pPacket = XFA_GetPacketByID(dwPacket); - CXFA_Node* pNewNode; + CXFA_Node* pNewNode = nullptr; for (; iCount <= index; iCount++) { pNewNode = pFactory->CreateNode(pPacket, eProperty); if (!pNewNode) { diff --git a/xfa/fxfa/parser/xfa_parser_imp.cpp b/xfa/fxfa/parser/xfa_parser_imp.cpp index 3369e59479..9cadcc6d1c 100644 --- a/xfa/fxfa/parser/xfa_parser_imp.cpp +++ b/xfa/fxfa/parser/xfa_parser_imp.cpp @@ -362,7 +362,6 @@ CXFA_Node* CXFA_SimpleParser::ParseAsXDPPacket(CFDE_XMLNode* pXMLDocumentNode, default: return ParseAsXDPPacket_User(pXMLDocumentNode, ePacketID); } - return NULL; } CXFA_Node* CXFA_SimpleParser::ParseAsXDPPacket_XDP( CFDE_XMLNode* pXMLDocumentNode, diff --git a/xfa/fxfa/parser/xfa_utils.h b/xfa/fxfa/parser/xfa_utils.h index 821e485e25..d6633a4c7f 100644 --- a/xfa/fxfa/parser/xfa_utils.h +++ b/xfa/fxfa/parser/xfa_utils.h @@ -120,7 +120,7 @@ class CXFA_NodeIteratorTemplate { NodeType** ppNode = NULL; NodeType* pCurrent = GetCurrent(); while (m_NodeStack.GetSize() > 0) { - while ((ppNode = m_NodeStack.GetTopElement())) { + while ((ppNode = m_NodeStack.GetTopElement()) != nullptr) { if (pCurrent != *ppNode) { return *ppNode; } @@ -130,7 +130,7 @@ class CXFA_NodeIteratorTemplate { } m_NodeStack.Push(pChild); } - while ((ppNode = m_NodeStack.GetTopElement())) { + while ((ppNode = m_NodeStack.GetTopElement()) != nullptr) { NodeType* pNext = TraverseStrategy::GetNextSibling(*ppNode); m_NodeStack.Pop(); if (m_NodeStack.GetSize() == 0) { @@ -145,8 +145,8 @@ class CXFA_NodeIteratorTemplate { return NULL; } NodeType* SkipChildrenAndMoveToNext() { - NodeType** ppNode = NULL; - while ((ppNode = m_NodeStack.GetTopElement())) { + NodeType** ppNode = nullptr; + while ((ppNode = m_NodeStack.GetTopElement()) != nullptr) { NodeType* pNext = TraverseStrategy::GetNextSibling(*ppNode); m_NodeStack.Pop(); if (m_NodeStack.GetSize() == 0) { diff --git a/xfa/fxfa/parser/xfa_utils_imp.cpp b/xfa/fxfa/parser/xfa_utils_imp.cpp index 77cac00b89..d576b4de06 100644 --- a/xfa/fxfa/parser/xfa_utils_imp.cpp +++ b/xfa/fxfa/parser/xfa_utils_imp.cpp @@ -255,14 +255,12 @@ FX_BOOL XFA_IsLayoutElement(XFA_ELEMENT eElement, FX_BOOL bLayoutContainer) { case XFA_ELEMENT_Subform: case XFA_ELEMENT_ExclGroup: case XFA_ELEMENT_SubformSet: - return TRUE; case XFA_ELEMENT_PageArea: case XFA_ELEMENT_Form: return TRUE; default: return FALSE; } - return FALSE; } static const FX_DOUBLE fraction_scales[] = {0.1, |