summaryrefslogtreecommitdiff
path: root/core/fpdfdoc
diff options
context:
space:
mode:
authorRalf Sippl <ralf.sippl@gmail.com>2018-04-12 21:20:26 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-04-12 21:20:26 +0000
commit1638179e85863b5045fcea2282fd3e0622aeac13 (patch)
treee21cc4c409ed04ccb4496f17c4edcc0d8f586cdc /core/fpdfdoc
parentc9f4f0dbcaaf9e86ef2b64c844b094bd2f6b1a92 (diff)
downloadpdfium-1638179e85863b5045fcea2282fd3e0622aeac13.tar.xz
Add index parameter to quadpoints getter and setter.
This is needed for working with multiline text markup annotations. Based on https://pdfium-review.googlesource.com/12012. Bug: pdfium:1045 Change-Id: Ifb105996b8b950bb2d5fceaf754b4f571155aef4 Reviewed-on: https://pdfium-review.googlesource.com/29150 Commit-Queue: Lei Zhang <thestig@chromium.org> Reviewed-by: Lei Zhang <thestig@chromium.org> Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Diffstat (limited to 'core/fpdfdoc')
-rw-r--r--core/fpdfdoc/cpdf_annot.cpp2
-rw-r--r--core/fpdfdoc/cpdf_annot.h3
2 files changed, 3 insertions, 2 deletions
diff --git a/core/fpdfdoc/cpdf_annot.cpp b/core/fpdfdoc/cpdf_annot.cpp
index 42bda6e319..ef803c428d 100644
--- a/core/fpdfdoc/cpdf_annot.cpp
+++ b/core/fpdfdoc/cpdf_annot.cpp
@@ -229,7 +229,7 @@ CFX_FloatRect CPDF_Annot::RectFromQuadPointsArray(const CPDF_Array* pArray,
// static
CFX_FloatRect CPDF_Annot::BoundingRectFromQuadPoints(
- CPDF_Dictionary* pAnnotDict) {
+ const CPDF_Dictionary* pAnnotDict) {
CPDF_Array* pArray = pAnnotDict->GetArrayFor("QuadPoints");
if (!pArray)
return CFX_FloatRect();
diff --git a/core/fpdfdoc/cpdf_annot.h b/core/fpdfdoc/cpdf_annot.h
index 3f1164ad18..b2875949a3 100644
--- a/core/fpdfdoc/cpdf_annot.h
+++ b/core/fpdfdoc/cpdf_annot.h
@@ -69,7 +69,8 @@ class CPDF_Annot {
static ByteString AnnotSubtypeToString(CPDF_Annot::Subtype nSubtype);
static CFX_FloatRect RectFromQuadPointsArray(const CPDF_Array* pArray,
size_t nIndex);
- static CFX_FloatRect BoundingRectFromQuadPoints(CPDF_Dictionary* pAnnotDict);
+ static CFX_FloatRect BoundingRectFromQuadPoints(
+ const CPDF_Dictionary* pAnnotDict);
static CFX_FloatRect RectFromQuadPoints(CPDF_Dictionary* pAnnotDict,
size_t nIndex);
static size_t QuadPointCount(const CPDF_Array* pArray);