summaryrefslogtreecommitdiff
path: root/xfa/src/fxgraphics
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2016-02-29 13:23:13 -0800
committerTom Sepez <tsepez@chromium.org>2016-02-29 13:23:13 -0800
commitbec4ea1e64b8049c572dd088c9c09a94f49b2353 (patch)
tree14470b439a7f963beea6aff17c72ac3321dc2e0a /xfa/src/fxgraphics
parent3f157c7c6a5cdb92dd5df2a0b06c10ed83b472e8 (diff)
downloadpdfium-bec4ea1e64b8049c572dd088c9c09a94f49b2353.tar.xz
Pass rect by const reference in SetClip_Rect().
R=dsinclair@chromium.org Review URL: https://codereview.chromium.org/1745243002 .
Diffstat (limited to 'xfa/src/fxgraphics')
-rw-r--r--xfa/src/fxgraphics/src/fx_graphics.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/xfa/src/fxgraphics/src/fx_graphics.cpp b/xfa/src/fxgraphics/src/fx_graphics.cpp
index 301bd7c356..602382725f 100644
--- a/xfa/src/fxgraphics/src/fx_graphics.cpp
+++ b/xfa/src/fxgraphics/src/fx_graphics.cpp
@@ -485,11 +485,11 @@ FX_ERR CFX_Graphics::SetClipRect(const CFX_RectF& rect) {
case FX_CONTEXT_Device: {
if (!_renderDevice)
return FX_ERR_Property_Invalid;
- FX_RECT r(FXSYS_round(rect.left), FXSYS_round(rect.top),
- FXSYS_round(rect.right()), FXSYS_round(rect.bottom()));
- FX_BOOL result = _renderDevice->SetClip_Rect(&r);
- if (!result)
+ if (!_renderDevice->SetClip_Rect(
+ FX_RECT(FXSYS_round(rect.left), FXSYS_round(rect.top),
+ FXSYS_round(rect.right()), FXSYS_round(rect.bottom())))) {
return FX_ERR_Method_Not_Supported;
+ }
return FX_ERR_Succeeded;
}
default: { return FX_ERR_Property_Invalid; }