summaryrefslogtreecommitdiff
path: root/core/fxge/ge
diff options
context:
space:
mode:
authorNicolas Pena <npm@chromium.org>2017-04-07 14:12:31 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-04-07 18:29:13 +0000
commit6a5c20cd08748da5969cbab756c3e8a6dd27bfbc (patch)
tree09a5d7e2666b166dc55e94a48270f17741d22b22 /core/fxge/ge
parent1e8c39f18df6e597e079cce13d18d72631ef0fb9 (diff)
downloadpdfium-6a5c20cd08748da5969cbab756c3e8a6dd27bfbc.tar.xz
Remove the ICC transform where it is never initialized.
- All callers of CFX_DIBitmap methods use nullptr as the ICC Transform. - The CFX_ScanlineCompositor is always initialized with a null ICC transform. Many of its methods call TranslateScanline from the ICC module. This method casts just uses ((CLcmsCmm*)pTransform)->m_hTransform, and this should not be done when pTransform is nullptr. Change-Id: I1b846d1f20699fa017cb9a276be3214eb8fabd4b Reviewed-on: https://pdfium-review.googlesource.com/3931 Commit-Queue: Nicolás Peña <npm@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'core/fxge/ge')
-rw-r--r--core/fxge/ge/cfx_renderdevice.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/core/fxge/ge/cfx_renderdevice.cpp b/core/fxge/ge/cfx_renderdevice.cpp
index b100f4d2f9..46127ccb07 100644
--- a/core/fxge/ge/cfx_renderdevice.cpp
+++ b/core/fxge/ge/cfx_renderdevice.cpp
@@ -673,7 +673,7 @@ bool CFX_RenderDevice::FillRectWithBlend(const FX_RECT* pRect,
return false;
if (!bitmap->CompositeRect(0, 0, pRect->Width(), pRect->Height(), fill_color,
- 0, nullptr)) {
+ 0)) {
return false;
}
FX_RECT src_rect(0, 0, pRect->Width(), pRect->Height());
@@ -755,7 +755,7 @@ bool CFX_RenderDevice::SetDIBitsWithBlend(
}
if (!background->CompositeBitmap(0, 0, bg_pixel_width, bg_pixel_height,
pBitmap, src_rect.left, src_rect.top,
- blend_mode, nullptr, false, nullptr)) {
+ blend_mode, nullptr, false)) {
return false;
}
FX_RECT rect(0, 0, bg_pixel_width, bg_pixel_height);
@@ -1042,8 +1042,7 @@ bool CFX_RenderDevice::DrawNormalText(int nChars,
if (anti_alias == FXFT_RENDER_MODE_NORMAL) {
if (!bitmap->CompositeMask(left.ValueOrDie(), top.ValueOrDie(), ncols,
nrows, pGlyph, fill_color, 0, 0,
- FXDIB_BLEND_NORMAL, nullptr, false, 0,
- nullptr)) {
+ FXDIB_BLEND_NORMAL, nullptr, false, 0)) {
return false;
}
continue;