summaryrefslogtreecommitdiff
path: root/xfa/fxgraphics/cfx_shading.cpp
diff options
context:
space:
mode:
authorNicolas Pena <npm@chromium.org>2017-04-20 15:29:25 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-04-20 20:12:17 +0000
commitddfc3dcce42ad1dc805f29102f7d056a5809d489 (patch)
tree686e0f28269a8d1e3c9eb2e9806f76ee2cb4b9f5 /xfa/fxgraphics/cfx_shading.cpp
parent58532b670716d5fe3ab024475fa1aa1580ecfe5b (diff)
downloadpdfium-ddfc3dcce42ad1dc805f29102f7d056a5809d489.tar.xz
Let {Argb,Cmyk}Decode return tuples
Change-Id: Ic4e766d9417f9a9ece5f9e4269d0f96e1e91639b Reviewed-on: https://pdfium-review.googlesource.com/4392 Commit-Queue: Nicolás Peña <npm@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'xfa/fxgraphics/cfx_shading.cpp')
-rw-r--r--xfa/fxgraphics/cfx_shading.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/xfa/fxgraphics/cfx_shading.cpp b/xfa/fxgraphics/cfx_shading.cpp
index 7dc8ce3412..b099bb97b1 100644
--- a/xfa/fxgraphics/cfx_shading.cpp
+++ b/xfa/fxgraphics/cfx_shading.cpp
@@ -51,15 +51,15 @@ void CFX_Shading::InitArgbArray() {
int32_t r1;
int32_t g1;
int32_t b1;
- ArgbDecode(m_beginArgb, a1, r1, g1, b1);
+ std::tie(a1, r1, g1, b1) = ArgbDecode(m_beginArgb);
int32_t a2;
int32_t r2;
int32_t g2;
int32_t b2;
- ArgbDecode(m_endArgb, a2, r2, g2, b2);
+ std::tie(a2, r2, g2, b2) = ArgbDecode(m_endArgb);
- float f = (float)(FX_SHADING_Steps - 1);
+ float f = static_cast<float>(FX_SHADING_Steps - 1);
float aScale = 1.0 * (a2 - a1) / f;
float rScale = 1.0 * (r2 - r1) / f;
float gScale = 1.0 * (g2 - g1) / f;