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

Side by Side Diff: fpdfsdk/src/fpdfxfa/fpdfxfa_doc.cpp

Issue 1640033002: XFA: Remove dead AddDoRecord code. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: Created 4 years, 11 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 unified diff | Download patch
« no previous file with comments | « fpdfsdk/include/fsdk_mgr.h ('k') | xfa/include/fwl/basewidget/fwl_edit.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "fpdfsdk/include/fsdk_define.h" 7 #include "fpdfsdk/include/fsdk_define.h"
8 #include "fpdfsdk/include/fpdfxfa/fpdfxfa_doc.h" 8 #include "fpdfsdk/include/fpdfxfa/fpdfxfa_doc.h"
9 #include "fpdfsdk/include/fsdk_mgr.h" 9 #include "fpdfsdk/include/fsdk_mgr.h"
10 #include "fpdfsdk/include/fpdfxfa/fpdfxfa_app.h" 10 #include "fpdfsdk/include/fpdfxfa/fpdfxfa_app.h"
(...skipping 786 matching lines...) Expand 10 before | Expand all | Expand 10 after
797 if (CPDFSDK_InterForm* pInterForm = m_pSDKDoc->GetInterForm()) { 797 if (CPDFSDK_InterForm* pInterForm = m_pSDKDoc->GetInterForm()) {
798 FX_COLORREF color = pInterForm->GetHighlightColor(FPDF_FORMFIELD_XFA); 798 FX_COLORREF color = pInterForm->GetHighlightColor(FPDF_FORMFIELD_XFA);
799 uint8_t alpha = pInterForm->GetHighlightAlpha(); 799 uint8_t alpha = pInterForm->GetHighlightAlpha();
800 FX_ARGB argb = ArgbEncode((int)alpha, color); 800 FX_ARGB argb = ArgbEncode((int)alpha, color);
801 return argb; 801 return argb;
802 } 802 }
803 } 803 }
804 return 0; 804 return 0;
805 } 805 }
806 806
807 void CPDFXFA_Document::AddDoRecord(IXFA_Widget* hWidget) {
808 CPDFDoc_Environment* pEnv = m_pSDKDoc->GetEnv();
809 if (pEnv == NULL)
810 return;
811 return;
812 // pEnv->FFI_AddDoRecord(this, hWidget);
813 }
814
815 FX_BOOL CPDFXFA_Document::_NotifySubmit(FX_BOOL bPrevOrPost) { 807 FX_BOOL CPDFXFA_Document::_NotifySubmit(FX_BOOL bPrevOrPost) {
816 if (bPrevOrPost) 808 if (bPrevOrPost)
817 return _OnBeforeNotifySumbit(); 809 return _OnBeforeNotifySumbit();
818 else 810
819 _OnAfterNotifySumbit(); 811 _OnAfterNotifySumbit();
820 return TRUE; 812 return TRUE;
821 } 813 }
822 814
823 FX_BOOL CPDFXFA_Document::_OnBeforeNotifySumbit() { 815 FX_BOOL CPDFXFA_Document::_OnBeforeNotifySumbit() {
824 #ifdef PDF_ENABLE_XFA 816 #ifdef PDF_ENABLE_XFA
825 if (m_iDocType != DOCTYPE_DYNAMIC_XFA && m_iDocType != DOCTYPE_STATIC_XFA) 817 if (m_iDocType != DOCTYPE_DYNAMIC_XFA && m_iDocType != DOCTYPE_STATIC_XFA)
826 return TRUE; 818 return TRUE;
827 if (m_pXFADocView == NULL) 819 if (m_pXFADocView == NULL)
828 return TRUE; 820 return TRUE;
829 IXFA_WidgetHandler* pWidgetHandler = m_pXFADocView->GetWidgetHandler(); 821 IXFA_WidgetHandler* pWidgetHandler = m_pXFADocView->GetWidgetHandler();
(...skipping 434 matching lines...) Expand 10 before | Expand all | Expand 10 after
1264 } 1256 }
1265 1257
1266 return _GetHValueByName(szPropName, hValue, 1258 return _GetHValueByName(szPropName, hValue,
1267 m_pSDKDoc->GetEnv()->GetJSRuntime()); 1259 m_pSDKDoc->GetEnv()->GetJSRuntime());
1268 } 1260 }
1269 FX_BOOL CPDFXFA_Document::_GetHValueByName(const CFX_ByteStringC& utf8Name, 1261 FX_BOOL CPDFXFA_Document::_GetHValueByName(const CFX_ByteStringC& utf8Name,
1270 FXJSE_HVALUE hValue, 1262 FXJSE_HVALUE hValue,
1271 IJS_Runtime* runTime) { 1263 IJS_Runtime* runTime) {
1272 return runTime->GetHValueByName(utf8Name, hValue); 1264 return runTime->GetHValueByName(utf8Name, hValue);
1273 } 1265 }
OLDNEW
« no previous file with comments | « fpdfsdk/include/fsdk_mgr.h ('k') | xfa/include/fwl/basewidget/fwl_edit.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698