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

Side by Side Diff: fpdfsdk/src/fsdk_baseform.cpp

Issue 1422113003: Fix XFA compilation noise, part 1. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: Nits. Created 5 years, 1 month 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/src/fsdk_baseannot.cpp ('k') | fpdfsdk/src/javascript/JS_Runtime.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 "../../third_party/base/nonstd_unique_ptr.h" 7 #include "../../third_party/base/nonstd_unique_ptr.h"
8 #include "../include/fsdk_define.h" 8 #include "../include/fsdk_define.h"
9 #include "../include/fpdfxfa/fpdfxfa_doc.h" 9 #include "../include/fpdfxfa/fpdfxfa_doc.h"
10 #include "../include/fpdfxfa/fpdfxfa_util.h" 10 #include "../include/fpdfxfa/fpdfxfa_util.h"
(...skipping 2094 matching lines...) Expand 10 before | Expand all | Expand 10 after
2105 2105
2106 return TRUE; 2106 return TRUE;
2107 } 2107 }
2108 return FALSE; 2108 return FALSE;
2109 } 2109 }
2110 2110
2111 // CPDFSDK_XFAWidget 2111 // CPDFSDK_XFAWidget
2112 CPDFSDK_XFAWidget::CPDFSDK_XFAWidget(IXFA_Widget* pAnnot, 2112 CPDFSDK_XFAWidget::CPDFSDK_XFAWidget(IXFA_Widget* pAnnot,
2113 CPDFSDK_PageView* pPageView, 2113 CPDFSDK_PageView* pPageView,
2114 CPDFSDK_InterForm* pInterForm) 2114 CPDFSDK_InterForm* pInterForm)
2115 : CPDFSDK_Annot(pPageView), 2115 : CPDFSDK_Annot(pPageView), m_pInterForm(pInterForm), m_hXFAWidget(pAnnot) {
2116 m_hXFAWidget(pAnnot), 2116 }
2117 m_pInterForm(pInterForm) {}
2118 2117
2119 FX_BOOL CPDFSDK_XFAWidget::IsXFAField() { 2118 FX_BOOL CPDFSDK_XFAWidget::IsXFAField() {
2120 return TRUE; 2119 return TRUE;
2121 } 2120 }
2122 2121
2123 CFX_ByteString CPDFSDK_XFAWidget::GetType() const { 2122 CFX_ByteString CPDFSDK_XFAWidget::GetType() const {
2124 return FSDK_XFAWIDGET_TYPENAME; 2123 return FSDK_XFAWIDGET_TYPENAME;
2125 } 2124 }
2126 2125
2127 CFX_FloatRect CPDFSDK_XFAWidget::GetRect() { 2126 CFX_FloatRect CPDFSDK_XFAWidget::GetRect() const {
2128 CPDFSDK_PageView* pPageView = GetPageView(); 2127 CPDFSDK_PageView* pPageView = GetPageView();
2129 ASSERT(pPageView != NULL);
2130
2131 CPDFSDK_Document* pDocument = pPageView->GetSDKDocument(); 2128 CPDFSDK_Document* pDocument = pPageView->GetSDKDocument();
2132 ASSERT(pDocument != NULL);
2133
2134 CPDFXFA_Document* pDoc = pDocument->GetDocument(); 2129 CPDFXFA_Document* pDoc = pDocument->GetDocument();
2135 ASSERT(pDoc != NULL);
2136
2137 IXFA_DocView* pDocView = pDoc->GetXFADocView(); 2130 IXFA_DocView* pDocView = pDoc->GetXFADocView();
2138 ASSERT(pDocView != NULL);
2139
2140 IXFA_WidgetHandler* pWidgetHandler = pDocView->GetWidgetHandler(); 2131 IXFA_WidgetHandler* pWidgetHandler = pDocView->GetWidgetHandler();
2141 ASSERT(pWidgetHandler != NULL);
2142 2132
2143 CFX_RectF rcBBox; 2133 CFX_RectF rcBBox;
2144 pWidgetHandler->GetRect(GetXFAWidget(), rcBBox); 2134 pWidgetHandler->GetRect(GetXFAWidget(), rcBBox);
2145 2135
2146 return CFX_FloatRect(rcBBox.left, rcBBox.top, rcBBox.left + rcBBox.width, 2136 return CFX_FloatRect(rcBBox.left, rcBBox.top, rcBBox.left + rcBBox.width,
2147 rcBBox.top + rcBBox.height); 2137 rcBBox.top + rcBBox.height);
2148 } 2138 }
2149 2139
2150 // CPDFSDK_InterForm 2140 // CPDFSDK_InterForm
2151 CPDFSDK_InterForm::CPDFSDK_InterForm(CPDFSDK_Document* pDocument) 2141 CPDFSDK_InterForm::CPDFSDK_InterForm(CPDFSDK_Document* pDocument)
(...skipping 1082 matching lines...) Expand 10 before | Expand all | Expand 10 after
3234 break; 3224 break;
3235 } 3225 }
3236 } 3226 }
3237 } 3227 }
3238 3228
3239 CPDF_Rect CBA_AnnotIterator::GetAnnotRect(CPDFSDK_Annot* pAnnot) { 3229 CPDF_Rect CBA_AnnotIterator::GetAnnotRect(CPDFSDK_Annot* pAnnot) {
3240 CPDF_Rect rcAnnot; 3230 CPDF_Rect rcAnnot;
3241 pAnnot->GetPDFAnnot()->GetRect(rcAnnot); 3231 pAnnot->GetPDFAnnot()->GetRect(rcAnnot);
3242 return rcAnnot; 3232 return rcAnnot;
3243 } 3233 }
OLDNEW
« no previous file with comments | « fpdfsdk/src/fsdk_baseannot.cpp ('k') | fpdfsdk/src/javascript/JS_Runtime.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698