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

Unified Diff: fpdfsdk/fsdk_mgr.cpp

Issue 2278153005: CPDF_Annot::GetRect() should return CFX_FloatRect. (Closed)
Patch Set: Created 4 years, 4 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « fpdfsdk/fpdfeditpage.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/fsdk_mgr.cpp
diff --git a/fpdfsdk/fsdk_mgr.cpp b/fpdfsdk/fsdk_mgr.cpp
index 24efd4077d74b2ab8ffc0c74f63317e2152762eb..9017e20b3277f0782ada51639867141ef31249ba 100644
--- a/fpdfsdk/fsdk_mgr.cpp
+++ b/fpdfsdk/fsdk_mgr.cpp
@@ -576,8 +576,7 @@ void CPDFSDK_PageView::PageView_OnDraw(CFX_RenderDevice* pDevice,
const CPDF_Annot* CPDFSDK_PageView::GetPDFAnnotAtPoint(FX_FLOAT pageX,
FX_FLOAT pageY) {
for (const auto& pAnnot : m_pAnnotList->All()) {
- CFX_FloatRect annotRect;
- pAnnot->GetRect(annotRect);
+ CFX_FloatRect annotRect = pAnnot->GetRect();
if (annotRect.Contains(pageX, pageY))
return pAnnot.get();
}
@@ -588,8 +587,7 @@ const CPDF_Annot* CPDFSDK_PageView::GetPDFWidgetAtPoint(FX_FLOAT pageX,
FX_FLOAT pageY) {
for (const auto& pAnnot : m_pAnnotList->All()) {
if (pAnnot->GetSubType() == "Widget") {
- CFX_FloatRect annotRect;
- pAnnot->GetRect(annotRect);
+ CFX_FloatRect annotRect = pAnnot->GetRect();
if (annotRect.Contains(pageX, pageY))
return pAnnot.get();
}
« no previous file with comments | « fpdfsdk/fpdfeditpage.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698