diff options
author | dan sinclair <dsinclair@chromium.org> | 2017-07-12 22:05:28 -0400 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2017-07-13 17:21:35 +0000 |
commit | 8db114ab60439f6d598ec68aa629f4385a532a92 (patch) | |
tree | c389f25e34010985ba1cfd1421e9be9234a7d5cf /fpdfsdk/pdfwindow/cpwl_caret.cpp | |
parent | adf922f278d23e7f955b89f48cc64b5de7925977 (diff) | |
download | pdfium-8db114ab60439f6d598ec68aa629f4385a532a92.tar.xz |
Use Translate instead of OffsetRect
This CL removes CPWL_Utils::OffsetRect in favour of CFX_FloatRect::Translate.
Change-Id: I10e654fcd32639f2121fa78cd343879562c54186
Reviewed-on: https://pdfium-review.googlesource.com/7711
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'fpdfsdk/pdfwindow/cpwl_caret.cpp')
-rw-r--r-- | fpdfsdk/pdfwindow/cpwl_caret.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fpdfsdk/pdfwindow/cpwl_caret.cpp b/fpdfsdk/pdfwindow/cpwl_caret.cpp index f49c77120c..def479a4df 100644 --- a/fpdfsdk/pdfwindow/cpwl_caret.cpp +++ b/fpdfsdk/pdfwindow/cpwl_caret.cpp @@ -66,8 +66,8 @@ void CPWL_Caret::GetCaretApp(const CFX_PointF& ptOffset, CFX_FloatRect rcRect = GetCaretRect(); CFX_FloatRect rcClip = GetClipRect(); - rcRect = CPWL_Utils::OffsetRect(rcRect, ptOffset.x, ptOffset.y); - rcClip = CPWL_Utils::OffsetRect(rcClip, ptOffset.x, ptOffset.y); + rcRect.Translate(ptOffset.x, ptOffset.y); + rcClip.Translate(ptOffset.x, ptOffset.y); *psAppStream << "q\n"; if (!rcClip.IsEmpty()) { |