From 179bebb9a14dfd3ba91e9e068d4d436657a7c780 Mon Sep 17 00:00:00 2001 From: dsinclair Date: Tue, 5 Apr 2016 11:02:18 -0700 Subject: Rename GetCStr and GetPtr to match CFX_ByteString. This CL updates CFX_ByteStringC to use the more common c_str and raw_str instead of GetCStr and GetPtr. Review URL: https://codereview.chromium.org/1857713003 --- xfa/fgas/crt/fgas_stream.cpp | 2 +- xfa/fgas/localization/fgas_locale.cpp | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'xfa/fgas') diff --git a/xfa/fgas/crt/fgas_stream.cpp b/xfa/fgas/crt/fgas_stream.cpp index 94468e23da..02fa2109d1 100644 --- a/xfa/fgas/crt/fgas_stream.cpp +++ b/xfa/fgas/crt/fgas_stream.cpp @@ -1112,7 +1112,7 @@ int32_t CFX_TextStream::WriteString(const FX_WCHAR* pStr, int32_t iLength) { encoder.Input(*pStr++); } CFX_ByteStringC bsResult = encoder.GetResult(); - m_pStreamImp->WriteData((const uint8_t*)bsResult.GetCStr(), + m_pStreamImp->WriteData((const uint8_t*)bsResult.c_str(), bsResult.GetLength()); } return iLength; diff --git a/xfa/fgas/localization/fgas_locale.cpp b/xfa/fgas/localization/fgas_locale.cpp index 8cf80ce4f1..d6243effee 100644 --- a/xfa/fgas/localization/fgas_locale.cpp +++ b/xfa/fgas/localization/fgas_locale.cpp @@ -68,8 +68,8 @@ static FX_STRSIZE FX_Local_Find(const CFX_WideStringC& wsSymbols, return -1; } const FX_WCHAR* lpsz = - (const FX_WCHAR*)FXSYS_wcschr(wsSymbols.GetPtr() + nStart, ch); - return (lpsz == NULL) ? -1 : (FX_STRSIZE)(lpsz - wsSymbols.GetPtr()); + (const FX_WCHAR*)FXSYS_wcschr(wsSymbols.raw_str() + nStart, ch); + return (lpsz == NULL) ? -1 : (FX_STRSIZE)(lpsz - wsSymbols.raw_str()); } static const FX_WCHAR* const gs_LocalNumberSymbols[] = { L"decimal", L"grouping", L"percent", L"minus", @@ -3855,7 +3855,7 @@ FX_BOOL FX_TimeFromCanonical(const CFX_WideStringC& wsTime, uint8_t second = 0; uint16_t millisecond = 0; int cc_start = 0, cc = cc_start; - const FX_WCHAR* str = (const FX_WCHAR*)wsTime.GetPtr(); + const FX_WCHAR* str = (const FX_WCHAR*)wsTime.raw_str(); int len = wsTime.GetLength(); while (cc < len && cc < 2) { if (!FX_IsDigit(str[cc])) { @@ -4699,7 +4699,7 @@ CFX_Decimal::CFX_Decimal(FX_FLOAT val, uint8_t scale) { m_uFlags = FXMATH_DECIMAL_MAKEFLAGS(val < 0 && IsNotZero(), scale); } CFX_Decimal::CFX_Decimal(const CFX_WideStringC& strObj) { - const FX_WCHAR* str = strObj.GetPtr(); + const FX_WCHAR* str = strObj.raw_str(); const FX_WCHAR* strBound = str + strObj.GetLength(); FX_BOOL pointmet = 0; FX_BOOL negmet = 0; -- cgit v1.2.3