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

Unified Diff: core/src/fxge/dib/fx_dib_composite.cpp

Issue 1243883003: Fix else-after-returns throughout pdfium. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Rebase, Address comments. Created 5 years, 5 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 | « core/src/fxge/agg/src/fx_agg_driver.cpp ('k') | core/src/fxge/dib/fx_dib_convert.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/src/fxge/dib/fx_dib_composite.cpp
diff --git a/core/src/fxge/dib/fx_dib_composite.cpp b/core/src/fxge/dib/fx_dib_composite.cpp
index 69f2a6b27ca6da51ec2f26fca555216965cd394c..4cacfa60659f45ca98073d450d14dc00810bdedd 100644
--- a/core/src/fxge/dib/fx_dib_composite.cpp
+++ b/core/src/fxge/dib/fx_dib_composite.cpp
@@ -3974,7 +3974,8 @@ void CFX_ScanlineCompositor::CompositePalBitmapLine(uint8_t* dest_scan, const ui
if (m_SrcFormat == FXDIB_1bppRgb) {
if (m_DestFormat == FXDIB_8bppRgb) {
return;
- } else if(m_DestFormat == FXDIB_Argb) {
+ }
+ if(m_DestFormat == FXDIB_Argb) {
_CompositeRow_1bppRgb2Argb_NoBlend_RgbByteOrder(dest_scan, src_scan, src_left, width, m_pSrcPalette, clip_scan);
} else {
_CompositeRow_1bppRgb2Rgb_NoBlend_RgbByteOrder(dest_scan, src_scan, src_left, m_pSrcPalette, width, (m_DestFormat & 0xff) >> 3, clip_scan);
@@ -3982,7 +3983,8 @@ void CFX_ScanlineCompositor::CompositePalBitmapLine(uint8_t* dest_scan, const ui
} else {
if (m_DestFormat == FXDIB_8bppRgb) {
return;
- } else if (m_DestFormat == FXDIB_Argb) {
+ }
+ if (m_DestFormat == FXDIB_Argb) {
_CompositeRow_8bppRgb2Argb_NoBlend_RgbByteOrder(dest_scan, src_scan, width, m_pSrcPalette, clip_scan);
} else {
_CompositeRow_8bppRgb2Rgb_NoBlend_RgbByteOrder(dest_scan, src_scan, m_pSrcPalette, width, (m_DestFormat & 0xff) >> 3, clip_scan);
@@ -3993,7 +3995,8 @@ void CFX_ScanlineCompositor::CompositePalBitmapLine(uint8_t* dest_scan, const ui
if (m_DestFormat == FXDIB_8bppMask) {
_CompositeRow_Rgb2Mask(dest_scan, src_scan, width, clip_scan);
return;
- } else if ((m_DestFormat & 0xff) == 8) {
+ }
+ if ((m_DestFormat & 0xff) == 8) {
if (m_Transparency & 8) {
if (m_DestFormat & 0x0200) {
_CompositeRow_1bppPal2Graya(dest_scan, src_scan, src_left, (const uint8_t*)m_pSrcPalette, width, m_BlendType, clip_scan, dst_extra_alpha);
@@ -4244,7 +4247,8 @@ FX_BOOL CFX_DIBitmap::CompositeRect(int left, int top, int width, int height, FX
}
}
return TRUE;
- } else if (m_bpp == 1) {
+ }
+ if (m_bpp == 1) {
ASSERT(!IsCmykImage() && (uint8_t)(alpha_flag >> 8) == 0);
int left_shift = rect.left % 8;
int right_shift = rect.right % 8;
« no previous file with comments | « core/src/fxge/agg/src/fx_agg_driver.cpp ('k') | core/src/fxge/dib/fx_dib_convert.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698