Lots of small tweaks to make -gui compile without warnings with clang.

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30119 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
theraven 2010-04-10 20:33:30 +00:00
parent 3529a217e2
commit 3da9ac45b7
13 changed files with 38 additions and 31 deletions

View file

@ -1300,9 +1300,13 @@ nsanimation_progressMarkSorter(NSAnimationProgress first, NSAnimationProgress se
[self setTargetFrame: r]; [self setTargetFrame: r];
if (_effect == NSViewAnimationFadeOutEffect) if (_effect == NSViewAnimationFadeOutEffect)
/* subclassResponsibility */; {
[self subclassResponsibility: _cmd];
}
if (_effect == NSViewAnimationFadeInEffect) if (_effect == NSViewAnimationFadeInEffect)
/* subclassResponsibility */; {
[self subclassResponsibility: _cmd];
}
} }
else else
{ {
@ -1334,9 +1338,9 @@ nsanimation_progressMarkSorter(NSAnimationProgress first, NSAnimationProgress se
- (void) setCurrentProgress: (float)progress - (void) setCurrentProgress: (float)progress
{ {
[super setCurrentProgress: progress]; [super setCurrentProgress: progress];
if (_effect == NSViewAnimationFadeOutEffect) if (_effect == NSViewAnimationFadeOutEffect) {}
/* ??? TODO */; /* ??? TODO */;
if (_effect == NSViewAnimationFadeInEffect) if (_effect == NSViewAnimationFadeInEffect) {}
/* ??? TODO */; /* ??? TODO */;
if (progress>=1.0f) if (progress>=1.0f)

View file

@ -162,7 +162,7 @@ static int gs_gif_output(GifFileType *file, const GifByteType *buffer, int len)
}\ }\
else \ else \
{\ {\
NSLog(msg);\ NSLog(@"%@", msg);\
} }
#define GIF_CREATE_ERROR(msg) \ #define GIF_CREATE_ERROR(msg) \

View file

@ -491,7 +491,7 @@ static void gs_jpeg_memory_dest_destroy (j_compress_ptr cinfo)
if (jerrMgr.parent.num_warnings) if (jerrMgr.parent.num_warnings)
{ {
NSLog(@"NSBitmapImageRep+JPEG: %d warnings during jpeg decompression, " NSLog(@"NSBitmapImageRep+JPEG: %ld warnings during jpeg decompression, "
@"image may be corrupted", jerrMgr.parent.num_warnings); @"image may be corrupted", jerrMgr.parent.num_warnings);
} }
@ -549,7 +549,7 @@ static void gs_jpeg_memory_dest_destroy (j_compress_ptr cinfo)
if (errorMsg != NULL) if (errorMsg != NULL)
*errorMsg = em; *errorMsg = em;
else else
NSLog (em); NSLog (@"JPEG image rep: Planar Image, not handled yet !");
return nil; return nil;
} }

View file

@ -144,7 +144,7 @@ static NSFont *_leafFont;
{ {
NSBrowserCell *c = [super copyWithZone: zone]; NSBrowserCell *c = [super copyWithZone: zone];
TEST_RETAIN (_alternateImage); _alternateImage = TEST_RETAIN (_alternateImage);
//c->_browsercell_is_leaf = _browsercell_is_leaf; //c->_browsercell_is_leaf = _browsercell_is_leaf;
//c->_browsercell_is_loaded = _browsercell_is_loaded; //c->_browsercell_is_loaded = _browsercell_is_loaded;

View file

@ -1477,11 +1477,11 @@ typedef struct _GSButtonCellFlags
NSButtonCell *c = [super copyWithZone: zone]; NSButtonCell *c = [super copyWithZone: zone];
c->_altContents = [_altContents copyWithZone: zone]; c->_altContents = [_altContents copyWithZone: zone];
TEST_RETAIN(_altImage); _altImage = TEST_RETAIN(_altImage);
TEST_RETAIN(_keyEquivalent); _keyEquivalent = TEST_RETAIN(_keyEquivalent);
TEST_RETAIN(_keyEquivalentFont); _keyEquivalentFont = TEST_RETAIN(_keyEquivalentFont);
TEST_RETAIN(_sound); _sound = TEST_RETAIN(_sound);
TEST_RETAIN(_backgroundColor); _backgroundColor = TEST_RETAIN(_backgroundColor);
return c; return c;
} }

View file

@ -2326,12 +2326,12 @@ static NSColor *dtxtCol;
/* Because of performance issues (and because so the doc says) only /* Because of performance issues (and because so the doc says) only
pointers to the objects are copied. We need to RETAIN them all pointers to the objects are copied. We need to RETAIN them all
though. */ though. */
TEST_RETAIN (_font); _font = TEST_RETAIN (_font);
TEST_RETAIN (_object_value); _object_value = TEST_RETAIN (_object_value);
TEST_RETAIN (_menu); _menu = TEST_RETAIN (_menu);
TEST_RETAIN (_cell_image); _cell_image = TEST_RETAIN (_cell_image);
TEST_RETAIN (_formatter); _formatter = TEST_RETAIN (_formatter);
TEST_RETAIN (_represented_object); _formatter = TEST_RETAIN (_represented_object);
return c; return c;
} }

View file

@ -376,7 +376,7 @@ NSGraphicsContext *GSCurrentContext(void)
- (void) setFocusStack: (void *)stack - (void) setFocusStack: (void *)stack
{ {
ASSIGN(focus_stack, stack); ASSIGN(focus_stack, (id)stack);
} }
- (void) setImageInterpolation: (NSImageInterpolation)interpolation - (void) setImageInterpolation: (NSImageInterpolation)interpolation

View file

@ -186,7 +186,7 @@
- (void)setRepresentedObject:(id <NSCopying>)anObject - (void)setRepresentedObject:(id <NSCopying>)anObject
{ {
ASSIGN(_representedObject, anObject); ASSIGN(_representedObject, (id)anObject);
} }
- (id <NSCopying>)representedObject - (id <NSCopying>)representedObject

View file

@ -650,7 +650,7 @@ inSpellDocumentWithTag:(int)tag
if (proxy != nil) if (proxy != nil)
{ {
ASSIGN(_language, language); ASSIGN(_language, language);
ASSIGN(_serverProxy, proxy); ASSIGN(_serverProxy, (id)proxy);
} }
else else
{ {

View file

@ -338,10 +338,14 @@
{ {
NSTextBlock *t = (NSTextBlock*)NSCopyObject(self, 0, zone); NSTextBlock *t = (NSTextBlock*)NSCopyObject(self, 0, zone);
TEST_RETAIN(_backgroundColor); _backgroundColor = TEST_RETAIN(_backgroundColor);
_borderColorForEdge[NSMinXEdge] =
TEST_RETAIN(_borderColorForEdge[NSMinXEdge]); TEST_RETAIN(_borderColorForEdge[NSMinXEdge]);
_borderColorForEdge[NSMinYEdge] =
TEST_RETAIN(_borderColorForEdge[NSMinYEdge]); TEST_RETAIN(_borderColorForEdge[NSMinYEdge]);
_borderColorForEdge[NSMaxXEdge] =
TEST_RETAIN(_borderColorForEdge[NSMaxXEdge]); TEST_RETAIN(_borderColorForEdge[NSMaxXEdge]);
_borderColorForEdge[NSMaxYEdge] =
TEST_RETAIN(_borderColorForEdge[NSMaxYEdge]); TEST_RETAIN(_borderColorForEdge[NSMaxYEdge]);
return t; return t;

View file

@ -154,7 +154,7 @@
{ {
NSTextList *l = (NSTextList*)NSCopyObject(self, 0, zone); NSTextList *l = (NSTextList*)NSCopyObject(self, 0, zone);
TEST_RETAIN(_markerFormat); _markerFormat = TEST_RETAIN(_markerFormat);
return l; return l;
} }

View file

@ -87,7 +87,7 @@
{ {
NSTextTableBlock *t = [super copyWithZone: zone]; NSTextTableBlock *t = [super copyWithZone: zone];
TEST_RETAIN(_table); _table = TEST_RETAIN(_table);
return t; return t;
} }

View file

@ -3787,8 +3787,7 @@ static NSView* findByTag(NSView *view, int aTag, unsigned *level)
*/ */
if (_rFlags.has_draginfo == 1 && _window != nil) if (_rFlags.has_draginfo == 1 && _window != nil)
{ {
o = GSGetDragTypes(self); o = TEST_RETAIN(GSGetDragTypes(self));
TEST_RETAIN(o);
} }
else else
{ {