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

Unified Diff: core/fpdfdoc/doc_form.cpp

Issue 1902953002: Remove a few more char* members from structs/classes. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 8 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 | « no previous file | core/fxcrt/include/fx_string.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/fpdfdoc/doc_form.cpp
diff --git a/core/fpdfdoc/doc_form.cpp b/core/fpdfdoc/doc_form.cpp
index 5062b454524249bbea695e7a2ef4ab61ca5d5fb9..d356a5c0e1cda41b2da87319f59bdf357547003c 100644
--- a/core/fpdfdoc/doc_form.cpp
+++ b/core/fpdfdoc/doc_form.cpp
@@ -48,11 +48,12 @@ CFX_WideString FPDFDOC_FDF_GetFieldValue(const CPDF_Dictionary& pFieldDict,
class CFieldNameExtractor {
public:
- explicit CFieldNameExtractor(const CFX_WideString& full_name) {
- m_pStart = full_name.c_str();
- m_pEnd = m_pStart + full_name.GetLength();
- m_pCur = m_pStart;
+ explicit CFieldNameExtractor(const CFX_WideString& full_name)
+ : m_FullName(full_name) {
+ m_pCur = m_FullName.c_str();
+ m_pEnd = m_pCur + m_FullName.GetLength();
}
+
void GetNext(const FX_WCHAR*& pSubName, FX_STRSIZE& size) {
pSubName = m_pCur;
while (m_pCur < m_pEnd && m_pCur[0] != L'.') {
@@ -65,10 +66,11 @@ class CFieldNameExtractor {
}
protected:
- const FX_WCHAR* m_pStart;
- const FX_WCHAR* m_pEnd;
+ CFX_WideString m_FullName;
const FX_WCHAR* m_pCur;
+ const FX_WCHAR* m_pEnd;
};
+
class CFieldTree {
public:
struct _Node {
« no previous file with comments | « no previous file | core/fxcrt/include/fx_string.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698