GIF loader: Indent.

And remove now unused label "finish".
This commit is contained in:
Kim Woelders 2016-04-04 19:57:37 +02:00
parent 1efd421614
commit a8ca99a2a4
1 changed files with 25 additions and 25 deletions

View File

@ -145,7 +145,7 @@ load(ImlibImage * im, ImlibProgressFunction progress, char progress_granularity,
bg = gif->SBackGroundColor; bg = gif->SBackGroundColor;
cmap = (gif->Image.ColorMap ? gif->Image.ColorMap : gif->SColorMap); cmap = (gif->Image.ColorMap ? gif->Image.ColorMap : gif->SColorMap);
memset (colormap, 0, sizeof(colormap)); memset(colormap, 0, sizeof(colormap));
if (cmap != NULL) if (cmap != NULL)
{ {
for (i = cmap->ColorCount > 256 ? 256 : cmap->ColorCount; i-- > 0;) for (i = cmap->ColorCount > 256 ? 256 : cmap->ColorCount; i-- > 0;)
@ -157,7 +157,8 @@ load(ImlibImage * im, ImlibProgressFunction progress, char progress_granularity,
} }
/* if bg > cmap->ColorCount, it is transparent black already */ /* if bg > cmap->ColorCount, it is transparent black already */
if (transp >= 0 && transp < 256) if (transp >= 0 && transp < 256)
colormap[transp] = bg >= 0 && bg < 256 ? colormap[bg] & 0x00ffffff : 0x00000000; colormap[transp] = bg >= 0 && bg < 256 ?
colormap[bg] & 0x00ffffff : 0x00000000;
} }
im->data = (DATA32 *) malloc(sizeof(DATA32) * w * h); im->data = (DATA32 *) malloc(sizeof(DATA32) * w * h);
if (!im->data) if (!im->data)
@ -185,7 +186,6 @@ load(ImlibImage * im, ImlibProgressFunction progress, char progress_granularity,
} }
} }
finish:
if (progress) if (progress)
progress(im, 100, 0, last_y, w, h); progress(im, 100, 0, last_y, w, h);
} }