OLD | NEW |
1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "core/fpdfapi/fpdf_font/include/cpdf_fontencoding.h" | 9 #include "core/fpdfapi/fpdf_font/include/cpdf_fontencoding.h" |
10 #include "core/fpdfapi/fpdf_page/include/cpdf_page.h" | 10 #include "core/fpdfapi/fpdf_page/include/cpdf_page.h" |
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
287 for (auto it : m_ControlMap) | 287 for (auto it : m_ControlMap) |
288 delete it.second; | 288 delete it.second; |
289 | 289 |
290 int nCount = m_pFieldTree->m_Root.CountFields(); | 290 int nCount = m_pFieldTree->m_Root.CountFields(); |
291 for (int i = 0; i < nCount; ++i) { | 291 for (int i = 0; i < nCount; ++i) { |
292 delete m_pFieldTree->m_Root.GetField(i); | 292 delete m_pFieldTree->m_Root.GetField(i); |
293 } | 293 } |
294 } | 294 } |
295 | 295 |
296 FX_BOOL CPDF_InterForm::s_bUpdateAP = TRUE; | 296 FX_BOOL CPDF_InterForm::s_bUpdateAP = TRUE; |
297 FX_BOOL CPDF_InterForm::UpdatingAPEnabled() { | 297 |
| 298 FX_BOOL CPDF_InterForm::IsUpdateAPEnabled() { |
298 return s_bUpdateAP; | 299 return s_bUpdateAP; |
299 } | 300 } |
300 void CPDF_InterForm::EnableUpdateAP(FX_BOOL bUpdateAP) { | 301 |
| 302 void CPDF_InterForm::SetUpdateAP(FX_BOOL bUpdateAP) { |
301 s_bUpdateAP = bUpdateAP; | 303 s_bUpdateAP = bUpdateAP; |
302 } | 304 } |
| 305 |
303 CFX_ByteString CPDF_InterForm::GenerateNewResourceName( | 306 CFX_ByteString CPDF_InterForm::GenerateNewResourceName( |
304 const CPDF_Dictionary* pResDict, | 307 const CPDF_Dictionary* pResDict, |
305 const FX_CHAR* csType, | 308 const FX_CHAR* csType, |
306 int iMinLen, | 309 int iMinLen, |
307 const FX_CHAR* csPrefix) { | 310 const FX_CHAR* csPrefix) { |
308 CFX_ByteString csStr = csPrefix; | 311 CFX_ByteString csStr = csPrefix; |
309 CFX_ByteString csBType = csType; | 312 CFX_ByteString csBType = csType; |
310 if (csStr.IsEmpty()) { | 313 if (csStr.IsEmpty()) { |
311 if (csBType == "ExtGState") { | 314 if (csBType == "ExtGState") { |
312 csStr = "GS"; | 315 csStr = "GS"; |
(...skipping 876 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1189 FDF_ImportField(pField, L"", bNotify); | 1192 FDF_ImportField(pField, L"", bNotify); |
1190 } | 1193 } |
1191 if (bNotify && m_pFormNotify) | 1194 if (bNotify && m_pFormNotify) |
1192 m_pFormNotify->AfterFormImportData(this); | 1195 m_pFormNotify->AfterFormImportData(this); |
1193 return TRUE; | 1196 return TRUE; |
1194 } | 1197 } |
1195 | 1198 |
1196 void CPDF_InterForm::SetFormNotify(IPDF_FormNotify* pNotify) { | 1199 void CPDF_InterForm::SetFormNotify(IPDF_FormNotify* pNotify) { |
1197 m_pFormNotify = pNotify; | 1200 m_pFormNotify = pNotify; |
1198 } | 1201 } |
OLD | NEW |