summaryrefslogtreecommitdiff
path: root/fpdfsdk/fpdftext.cpp
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2017-02-21 14:31:41 -0500
committerChromium commit bot <commit-bot@chromium.org>2017-02-21 21:43:40 +0000
commitd476adcab3b1b79b921c0003f8d8caad1bb1d00b (patch)
treea285cd1b03159e34c1c5ecde897d0a3364cd03b8 /fpdfsdk/fpdftext.cpp
parentb45ea1fce52d93615470bab8b671cba5907fb01e (diff)
downloadpdfium-d476adcab3b1b79b921c0003f8d8caad1bb1d00b.tar.xz
Remove non CFX_PointF GetIndexAtPos
This Cl removes the overload that takes a x,y position and uses the CFX_PointF version in all cases. Change-Id: Iebd048d91a1e1ed1c90ec0019e19750afe06e745 Reviewed-on: https://pdfium-review.googlesource.com/2812 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org> Reviewed-by: Nicolás Peña <npm@chromium.org>
Diffstat (limited to 'fpdfsdk/fpdftext.cpp')
-rw-r--r--fpdfsdk/fpdftext.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/fpdfsdk/fpdftext.cpp b/fpdfsdk/fpdftext.cpp
index 629e596c8d..0432afd707 100644
--- a/fpdfsdk/fpdftext.cpp
+++ b/fpdfsdk/fpdftext.cpp
@@ -133,8 +133,10 @@ DLLEXPORT int STDCALL FPDFText_GetCharIndexAtPos(FPDF_TEXTPAGE text_page,
return -3;
CPDF_TextPage* textpage = CPDFTextPageFromFPDFTextPage(text_page);
- return textpage->GetIndexAtPos((FX_FLOAT)x, (FX_FLOAT)y, (FX_FLOAT)xTolerance,
- (FX_FLOAT)yTolerance);
+ return textpage->GetIndexAtPos(
+ CFX_PointF(static_cast<FX_FLOAT>(x), static_cast<FX_FLOAT>(y)),
+ CFX_SizeF(static_cast<FX_FLOAT>(xTolerance),
+ static_cast<FX_FLOAT>(yTolerance)));
}
DLLEXPORT int STDCALL FPDFText_GetText(FPDF_TEXTPAGE text_page,