summaryrefslogtreecommitdiff
path: root/fpdfsdk/cpdfsdk_pageview.cpp
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2018-10-09 19:13:55 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-10-09 19:13:55 +0000
commit09ee087b894679ff7bc6bc17c7e8a8410e00f8b5 (patch)
tree7558e4680970e1657c9769785317d3d63cd6de69 /fpdfsdk/cpdfsdk_pageview.cpp
parentf9718052794c4669a4f99d8f798806c9730a9e36 (diff)
downloadpdfium-09ee087b894679ff7bc6bc17c7e8a8410e00f8b5.tar.xz
Pass CFX_Matrix by const-ref in various OnDraw() methods.
Change-Id: I6e953206520c024b2fc23b9b60c5c43112d04896 Reviewed-on: https://pdfium-review.googlesource.com/c/43603 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
Diffstat (limited to 'fpdfsdk/cpdfsdk_pageview.cpp')
-rw-r--r--fpdfsdk/cpdfsdk_pageview.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/fpdfsdk/cpdfsdk_pageview.cpp b/fpdfsdk/cpdfsdk_pageview.cpp
index 0713d29a5f..ff87ea8465 100644
--- a/fpdfsdk/cpdfsdk_pageview.cpp
+++ b/fpdfsdk/cpdfsdk_pageview.cpp
@@ -63,10 +63,10 @@ CPDFSDK_PageView::~CPDFSDK_PageView() {
}
void CPDFSDK_PageView::PageView_OnDraw(CFX_RenderDevice* pDevice,
- CFX_Matrix* pUser2Device,
+ const CFX_Matrix& mtUser2Device,
CPDF_RenderOptions* pOptions,
const FX_RECT& pClip) {
- m_curMatrix = *pUser2Device;
+ m_curMatrix = mtUser2Device;
#ifdef PDF_ENABLE_XFA
CPDFXFA_Page* pPage = GetPDFXFAPage();
@@ -83,7 +83,7 @@ void CPDFSDK_PageView::PageView_OnDraw(CFX_RenderDevice* pDevice,
gs.SetClipRect(rectClip);
CXFA_FFPageView* xfaView = pPage->GetXFAPageView();
- CXFA_RenderContext renderContext(xfaView, rectClip, *pUser2Device);
+ CXFA_RenderContext renderContext(xfaView, rectClip, mtUser2Device);
renderContext.DoRender(&gs);
CXFA_FFDocView* docView = xfaView->GetDocView();
@@ -94,7 +94,7 @@ void CPDFSDK_PageView::PageView_OnDraw(CFX_RenderDevice* pDevice,
return;
// Render the focus widget
docView->GetWidgetHandler()->RenderWidget(annot->GetXFAWidget(), &gs,
- *pUser2Device, false);
+ mtUser2Device, false);
return;
}
#endif // PDF_ENABLE_XFA
@@ -103,7 +103,7 @@ void CPDFSDK_PageView::PageView_OnDraw(CFX_RenderDevice* pDevice,
CPDFSDK_AnnotIteration annotIteration(this, true);
for (const auto& pSDKAnnot : annotIteration) {
m_pFormFillEnv->GetAnnotHandlerMgr()->Annot_OnDraw(
- this, pSDKAnnot.Get(), pDevice, pUser2Device,
+ this, pSDKAnnot.Get(), pDevice, mtUser2Device,
pOptions->GetDrawAnnots());
}
}