From 69ad278881f83a1f8cf45d5a42a88752c0871c7e Mon Sep 17 00:00:00 2001 From: Jane Liu Date: Fri, 18 Aug 2017 14:42:58 -0400 Subject: Converted CFX_FloatRect::{Init|Update}Rect() to take point objects Converted CFX_FloatRect::Init() and CFX_FloatRect::UpdateRect() to take in a CFX_PointF object instead of two coordinates. Bug=pdfium:770 Change-Id: Ibcb620f192d6c086158c39f23c411777286005d0 Reviewed-on: https://pdfium-review.googlesource.com/11450 Commit-Queue: dsinclair Reviewed-by: dsinclair --- core/fxcrt/fx_coordinates.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'core/fxcrt/fx_coordinates.h') diff --git a/core/fxcrt/fx_coordinates.h b/core/fxcrt/fx_coordinates.h index 86b921d85c..cc14508d70 100644 --- a/core/fxcrt/fx_coordinates.h +++ b/core/fxcrt/fx_coordinates.h @@ -274,13 +274,13 @@ class CFX_FloatRect { int Substract4(CFX_FloatRect& substract_rect, CFX_FloatRect* pRects); - void InitRect(float x, float y) { - left = x; - right = x; - bottom = y; - top = y; + void InitRect(const CFX_PointF& point) { + left = point.x; + right = point.x; + bottom = point.y; + top = point.y; } - void UpdateRect(float x, float y); + void UpdateRect(const CFX_PointF& point); float Width() const { return right - left; } float Height() const { return top - bottom; } -- cgit v1.2.3