mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-22 13:10:59 +00:00
use defined() to check if a variable is defined, also, rename it to be clearer about a feature availability and not enabling one
This commit is contained in:
parent
31a71a1090
commit
34c5a5e841
1 changed files with 3 additions and 3 deletions
|
@ -71,7 +71,7 @@ objective-c headers.
|
|||
// GifQuantizeBuffer is considered private API on GIF 5.2 and later:
|
||||
// https://sourceforge.net/p/giflib/code/ci/befe188771035de7acbc2ad46bea22ea73ab09cd/
|
||||
#if (GIFLIB_MAJOR == 5 && GIFLIB_MINOR < 2) || GIFLIB_MAJOR < 5
|
||||
#define PUBLIC_QUANTIZEBUFFER
|
||||
#define IS_QUANTIZEBUFFER_PUBLIC
|
||||
#endif
|
||||
|
||||
/* -----------------------------------------------------------
|
||||
|
@ -134,7 +134,7 @@ static void gs_gif_init_input_source(gs_gif_input_src *src, NSData *data)
|
|||
src->pos = 0;
|
||||
}
|
||||
|
||||
#if (HAVE_QUANTIZEBUFFER || HAVE_GIFQUANTIZEBUFFER) && PUBLIC_QUANTIZEBUFFER
|
||||
#if (defined(HAVE_QUANTIZEBUFFER) || defined(HAVE_GIFQUANTIZEBUFFER)) && defined(IS_QUANTIZEBUFFER_PUBLIC)
|
||||
/* Function to write GIF to buffer */
|
||||
static int gs_gif_output(GifFileType *file, const GifByteType *buffer, int len)
|
||||
{
|
||||
|
@ -410,7 +410,7 @@ static int gs_gif_output(GifFileType *file, const GifByteType *buffer, int len)
|
|||
- (NSData *) _GIFRepresentationWithProperties: (NSDictionary *) properties
|
||||
errorMessage: (NSString **)errorMsg
|
||||
{
|
||||
#if (HAVE_QUANTIZEBUFFER || HAVE_GIFQUANTIZEBUFFER) && PUBLIC_QUANTIZEBUFFER
|
||||
#if (defined(HAVE_QUANTIZEBUFFER) || defined(HAVE_GIFQUANTIZEBUFFER)) && defined(IS_QUANTIZEBUFFER_PUBLIC)
|
||||
NSMutableData * GIFRep = nil; // our return value
|
||||
GifFileType * GIFFile = NULL;
|
||||
GifByteType * rgbPlanes = NULL; // giflib needs planar RGB
|
||||
|
|
Loading…
Reference in a new issue