summaryrefslogtreecommitdiff
path: root/xfa/fxfa/parser/cxfa_itemlayoutprocessor.cpp
diff options
context:
space:
mode:
authorRyan Harrison <rharrison@chromium.org>2017-09-18 14:23:18 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-09-18 18:40:16 +0000
commit275e260a6cd4a8e506ba974feb85ebcd926c1739 (patch)
tree2029b9158ec044764ceff122fe5fb5d0a3f123d1 /xfa/fxfa/parser/cxfa_itemlayoutprocessor.cpp
parent450fbeaaabf1ab340c1018de2e58f1950657517e (diff)
downloadpdfium-275e260a6cd4a8e506ba974feb85ebcd926c1739.tar.xz
Convert string class names
Automated using git grep & sed. Replace StringC classes with StringView classes. Remove the CFX_ prefix and put string classes in fxcrt namespace. Change AsStringC() to AsStringView(). Rename tests from TEST(fxcrt, *String*Foo) to TEST(*String*, Foo). Couple of tests needed to have their names regularlized. BUG=pdfium:894 Change-Id: I7ca038685c8d803795f3ed02545124f7a224c83d Reviewed-on: https://pdfium-review.googlesource.com/14151 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Diffstat (limited to 'xfa/fxfa/parser/cxfa_itemlayoutprocessor.cpp')
-rw-r--r--xfa/fxfa/parser/cxfa_itemlayoutprocessor.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/xfa/fxfa/parser/cxfa_itemlayoutprocessor.cpp b/xfa/fxfa/parser/cxfa_itemlayoutprocessor.cpp
index f7a019d2d8..7d9a2188c8 100644
--- a/xfa/fxfa/parser/cxfa_itemlayoutprocessor.cpp
+++ b/xfa/fxfa/parser/cxfa_itemlayoutprocessor.cpp
@@ -29,10 +29,10 @@
namespace {
-std::vector<CFX_WideString> SeparateStringW(const wchar_t* pStr,
- int32_t iStrLen,
- wchar_t delimiter) {
- std::vector<CFX_WideString> ret;
+std::vector<WideString> SeparateStringW(const wchar_t* pStr,
+ int32_t iStrLen,
+ wchar_t delimiter) {
+ std::vector<WideString> ret;
if (!pStr)
return ret;
if (iStrLen < 0)
@@ -42,7 +42,7 @@ std::vector<CFX_WideString> SeparateStringW(const wchar_t* pStr,
const wchar_t* pEnd = pStr + iStrLen;
while (true) {
if (pStr >= pEnd || delimiter == *pStr) {
- ret.push_back(CFX_WideString(pToken, pStr - pToken));
+ ret.push_back(WideString(pToken, pStr - pToken));
pToken = pStr + 1;
if (pStr >= pEnd)
break;
@@ -1746,7 +1746,7 @@ void CXFA_ItemLayoutProcessor::DoLayoutTableContainer(CXFA_Node* pLayoutNode) {
float fContentWidthLimit =
bContainerWidthAutoSize ? FLT_MAX
: containerSize.width - fLeftInset - fRightInset;
- CFX_WideStringC wsColumnWidths;
+ WideStringView wsColumnWidths;
if (pLayoutNode->TryCData(XFA_ATTRIBUTE_ColumnWidths, wsColumnWidths)) {
auto widths = SeparateStringW(wsColumnWidths.unterminated_c_str(),
wsColumnWidths.GetLength(), L' ');
@@ -1756,7 +1756,7 @@ void CXFA_ItemLayoutProcessor::DoLayoutTableContainer(CXFA_Node* pLayoutNode) {
continue;
m_rgSpecifiedColumnWidths.push_back(
- CXFA_Measurement(width.AsStringC()).ToUnit(XFA_UNIT_Pt));
+ CXFA_Measurement(width.AsStringView()).ToUnit(XFA_UNIT_Pt));
}
}