mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-31 11:30:48 +00:00
Remove compiler warnings from clang.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30117 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
6e3460f08a
commit
cec34abb20
16 changed files with 74 additions and 45 deletions
21
ChangeLog
21
ChangeLog
|
@ -1,7 +1,26 @@
|
||||||
|
2010-04-10 Fred Kiefer <FredKiefer@gmx.de>
|
||||||
|
|
||||||
|
* Source/linking.m
|
||||||
|
* Source/GSDisplayServer.m
|
||||||
|
* Source/NSWorkspace.m
|
||||||
|
* Source/NSButtonCell.m
|
||||||
|
* Source/NSSplitView.m
|
||||||
|
* Source/GSNibLoading.m
|
||||||
|
* Source/NSCursor.m
|
||||||
|
* Source/NSScroller.m
|
||||||
|
* Source/NSOutlineView.m
|
||||||
|
* Source/GSToolbarView.m
|
||||||
|
* Source/GSPDFPrintOperation.m
|
||||||
|
* Source/GSThemePanel.m
|
||||||
|
* Source/NSImage.m
|
||||||
|
* Source/NSTableView.m
|
||||||
|
* Source/GSDragView.m: Remove compiler warnings detected by clang
|
||||||
|
and reported by David Chisnall <theraven@gna.org>.
|
||||||
|
|
||||||
2010-04-09 David Ayers <ayers@fsfe.org>
|
2010-04-09 David Ayers <ayers@fsfe.org>
|
||||||
|
|
||||||
* Headers/AppKit/NSSound.h: Import NSBundle.h for category declaration.
|
* Headers/AppKit/NSSound.h: Import NSBundle.h for category declaration.
|
||||||
|
|
||||||
2010-04-08 Jonathan Gillaspie <jonathan.gillaspie@testplant.com>
|
2010-04-08 Jonathan Gillaspie <jonathan.gillaspie@testplant.com>
|
||||||
|
|
||||||
* Source/GSToolTips.m: Prevent Windows API callback from crashing when displaying tooltips.
|
* Source/GSToolTips.m: Prevent Windows API callback from crashing when displaying tooltips.
|
||||||
|
|
|
@ -26,23 +26,24 @@
|
||||||
Boston, MA 02110-1301, USA.
|
Boston, MA 02110-1301, USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <Foundation/NSArray.h>
|
#import <Foundation/NSArray.h>
|
||||||
#include <Foundation/NSDictionary.h>
|
#import <Foundation/NSDictionary.h>
|
||||||
#include <Foundation/NSEnumerator.h>
|
#import <Foundation/NSEnumerator.h>
|
||||||
#include <Foundation/NSData.h>
|
#import <Foundation/NSData.h>
|
||||||
#include <Foundation/NSLock.h>
|
#import <Foundation/NSLock.h>
|
||||||
#include <Foundation/NSRunLoop.h>
|
#import <Foundation/NSRunLoop.h>
|
||||||
#include <Foundation/NSThread.h>
|
#import <Foundation/NSSet.h>
|
||||||
#include <Foundation/NSGeometry.h>
|
#import <Foundation/NSThread.h>
|
||||||
|
#import <Foundation/NSGeometry.h>
|
||||||
|
|
||||||
#include "AppKit/NSApplication.h"
|
#import "AppKit/NSApplication.h"
|
||||||
#include "AppKit/NSEvent.h"
|
#import "AppKit/NSEvent.h"
|
||||||
#include "AppKit/NSImage.h"
|
#import "AppKit/NSImage.h"
|
||||||
#include "AppKit/NSWindow.h"
|
#import "AppKit/NSWindow.h"
|
||||||
#include "GNUstepGUI/GSDisplayServer.h"
|
#import "GNUstepGUI/GSDisplayServer.h"
|
||||||
#include "GNUstepGUI/GSDragView.h"
|
#import "GNUstepGUI/GSDragView.h"
|
||||||
|
|
||||||
#include "GSSlideView.h"
|
#import "GSSlideView.h"
|
||||||
|
|
||||||
/* Display attributes */
|
/* Display attributes */
|
||||||
NSString * GSDisplayName = @"DisplayName";
|
NSString * GSDisplayName = @"DisplayName";
|
||||||
|
|
|
@ -623,7 +623,7 @@ static GSDragView *sharedDragView = nil;
|
||||||
startPoint = [eWindow convertBaseToScreen: [theEvent locationInWindow]];
|
startPoint = [eWindow convertBaseToScreen: [theEvent locationInWindow]];
|
||||||
startPoint.x -= offset.width;
|
startPoint.x -= offset.width;
|
||||||
startPoint.y -= offset.height;
|
startPoint.y -= offset.height;
|
||||||
NSDebugLLog(@"NSDragging", @"Drag window origin %d %d\n", startPoint.x, startPoint.y);
|
NSDebugLLog(@"NSDragging", @"Drag window origin %@\n", NSStringFromPoint(startPoint));
|
||||||
|
|
||||||
// Notify the source that dragging has started
|
// Notify the source that dragging has started
|
||||||
if ([dragSource respondsToSelector:
|
if ([dragSource respondsToSelector:
|
||||||
|
@ -888,7 +888,7 @@ static GSDragView *sharedDragView = nil;
|
||||||
dragPoint = [destWindow convertScreenToBase: dragPosition];
|
dragPoint = [destWindow convertScreenToBase: dragPosition];
|
||||||
}
|
}
|
||||||
|
|
||||||
NSDebugLLog(@"NSDragging", @"mouse window %d (%x) at %@\n",
|
NSDebugLLog(@"NSDragging", @"mouse window %d (%@) at %@\n",
|
||||||
mouseWindowRef, destWindow, NSStringFromPoint(dragPosition));
|
mouseWindowRef, destWindow, NSStringFromPoint(dragPosition));
|
||||||
|
|
||||||
//--- send exit message if necessary -------------------------------------
|
//--- send exit message if necessary -------------------------------------
|
||||||
|
|
|
@ -46,6 +46,7 @@
|
||||||
#import <Foundation/NSException.h>
|
#import <Foundation/NSException.h>
|
||||||
#import <Foundation/NSKeyedArchiver.h>
|
#import <Foundation/NSKeyedArchiver.h>
|
||||||
#import <Foundation/NSObjCRuntime.h>
|
#import <Foundation/NSObjCRuntime.h>
|
||||||
|
#import <Foundation/NSSet.h>
|
||||||
#import <Foundation/NSString.h>
|
#import <Foundation/NSString.h>
|
||||||
|
|
||||||
// FIXME: Used for NSKeyedArchiver access. All this should be moved into base.
|
// FIXME: Used for NSKeyedArchiver access. All this should be moved into base.
|
||||||
|
|
|
@ -33,12 +33,14 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#include <Foundation/NSPathUtilities.h>
|
#import <Foundation/NSData.h>
|
||||||
#include <Foundation/NSTask.h>
|
#import <Foundation/NSDictionary.h>
|
||||||
#include <Foundation/NSProcessInfo.h>
|
#import <Foundation/NSPathUtilities.h>
|
||||||
#include <Foundation/NSData.h>
|
#import <Foundation/NSTask.h>
|
||||||
#include "AppKit/NSView.h"
|
#import <Foundation/NSProcessInfo.h>
|
||||||
#include "GNUstepGUI/GSPDFPrintOperation.h"
|
#import "AppKit/NSPrintInfo.h"
|
||||||
|
#import "AppKit/NSView.h"
|
||||||
|
#import "GNUstepGUI/GSPDFPrintOperation.h"
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -26,15 +26,16 @@
|
||||||
Boston, MA 02110-1301, USA.
|
Boston, MA 02110-1301, USA.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <Foundation/NSFileManager.h>
|
#import <Foundation/NSFileManager.h>
|
||||||
#include <Foundation/NSNotification.h>
|
#import <Foundation/NSNotification.h>
|
||||||
#include <Foundation/NSPathUtilities.h>
|
#import <Foundation/NSPathUtilities.h>
|
||||||
#include <Foundation/NSUserDefaults.h>
|
#import <Foundation/NSSet.h>
|
||||||
#include "AppKit/NSButton.h"
|
#import <Foundation/NSUserDefaults.h>
|
||||||
#include "AppKit/NSMatrix.h"
|
#import "AppKit/NSButton.h"
|
||||||
#include "AppKit/NSScrollView.h"
|
#import "AppKit/NSMatrix.h"
|
||||||
#include "GSThemePrivate.h"
|
#import "AppKit/NSScrollView.h"
|
||||||
#include "GSGuiPrivate.h"
|
#import "GSThemePrivate.h"
|
||||||
|
#import "GSGuiPrivate.h"
|
||||||
|
|
||||||
|
|
||||||
@implementation GSThemePanel
|
@implementation GSThemePanel
|
||||||
|
|
|
@ -343,7 +343,7 @@ static void initSystemExtensionsColors(void)
|
||||||
[(NSToolbarItem *)[[info draggingSource] toolbarItem] itemIdentifier];
|
[(NSToolbarItem *)[[info draggingSource] toolbarItem] itemIdentifier];
|
||||||
|
|
||||||
if ([self _insertionIndexAtPoint: [info draggingLocation]] != NSNotFound
|
if ([self _insertionIndexAtPoint: [info draggingLocation]] != NSNotFound
|
||||||
&& [allowedItemIdentifiers containsObject: itemIdentifier]);
|
&& [allowedItemIdentifiers containsObject: itemIdentifier])
|
||||||
{
|
{
|
||||||
return NSDragOperationGeneric;
|
return NSDragOperationGeneric;
|
||||||
}
|
}
|
||||||
|
@ -360,7 +360,7 @@ static void initSystemExtensionsColors(void)
|
||||||
[(NSToolbarItem *)[[info draggingSource] toolbarItem] itemIdentifier];
|
[(NSToolbarItem *)[[info draggingSource] toolbarItem] itemIdentifier];
|
||||||
|
|
||||||
if ([self _insertionIndexAtPoint: [info draggingLocation]] != NSNotFound
|
if ([self _insertionIndexAtPoint: [info draggingLocation]] != NSNotFound
|
||||||
&& [allowedItemIdentifiers containsObject: itemIdentifier]);
|
&& [allowedItemIdentifiers containsObject: itemIdentifier])
|
||||||
{
|
{
|
||||||
return NSDragOperationGeneric;
|
return NSDragOperationGeneric;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1550,7 +1550,7 @@ typedef struct _GSButtonCellFlags
|
||||||
[aCoder encodeInt: bFlags forKey: @"NSButtonFlags"];
|
[aCoder encodeInt: bFlags forKey: @"NSButtonFlags"];
|
||||||
|
|
||||||
// style and border.
|
// style and border.
|
||||||
bFlags2 != [self showsBorderOnlyWhileMouseInside] ? 0x8 : 0;
|
bFlags2 |= [self showsBorderOnlyWhileMouseInside] ? 0x8 : 0;
|
||||||
bFlags2 |= (([self bezelStyle] & 0x7) | (([self bezelStyle] & 0x18) << 2));
|
bFlags2 |= (([self bezelStyle] & 0x7) | (([self bezelStyle] & 0x18) << 2));
|
||||||
bFlags2 |= [self keyEquivalentModifierMask] << 8;
|
bFlags2 |= [self keyEquivalentModifierMask] << 8;
|
||||||
[aCoder encodeInt: bFlags2 forKey: @"NSButtonFlags2"];
|
[aCoder encodeInt: bFlags2 forKey: @"NSButtonFlags2"];
|
||||||
|
|
|
@ -30,6 +30,7 @@
|
||||||
|
|
||||||
#include <Foundation/NSArray.h>
|
#include <Foundation/NSArray.h>
|
||||||
#include <Foundation/NSDebug.h>
|
#include <Foundation/NSDebug.h>
|
||||||
|
#include <Foundation/NSDictionary.h>
|
||||||
#include <Foundation/NSKeyedArchiver.h>
|
#include <Foundation/NSKeyedArchiver.h>
|
||||||
|
|
||||||
#include "AppKit/NSColor.h"
|
#include "AppKit/NSColor.h"
|
||||||
|
|
|
@ -1897,19 +1897,19 @@ iterate_reps_for_types(NSArray* imageReps, SEL method)
|
||||||
{
|
{
|
||||||
if (repd->bg == nil)
|
if (repd->bg == nil)
|
||||||
{
|
{
|
||||||
NSDebugLLog(@"NSImage", @"Invalid %@ ... %@ %d",
|
NSDebugLLog(@"NSImage", @"Invalid %@ ... %@ %@",
|
||||||
repd->bg, _color, repd->rep);
|
repd->bg, _color, repd->rep);
|
||||||
invalidCache = repd;
|
invalidCache = repd;
|
||||||
}
|
}
|
||||||
else if (opaque == YES || [repd->bg isEqual: _color] == YES)
|
else if (opaque == YES || [repd->bg isEqual: _color] == YES)
|
||||||
{
|
{
|
||||||
NSDebugLLog(@"NSImage", @"Exact %@ ... %@ %d",
|
NSDebugLLog(@"NSImage", @"Exact %@ ... %@ %@",
|
||||||
repd->bg, _color, repd->rep);
|
repd->bg, _color, repd->rep);
|
||||||
return repd;
|
return repd;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
NSDebugLLog(@"NSImage", @"Partial %@ ... %@ %d",
|
NSDebugLLog(@"NSImage", @"Partial %@ ... %@ %@",
|
||||||
repd->bg, _color, repd->rep);
|
repd->bg, _color, repd->rep);
|
||||||
partialCache = repd;
|
partialCache = repd;
|
||||||
partialCount++;
|
partialCount++;
|
||||||
|
|
|
@ -39,6 +39,7 @@
|
||||||
#import <Foundation/NSMapTable.h>
|
#import <Foundation/NSMapTable.h>
|
||||||
#import <Foundation/NSNotification.h>
|
#import <Foundation/NSNotification.h>
|
||||||
#import <Foundation/NSNull.h>
|
#import <Foundation/NSNull.h>
|
||||||
|
#import <Foundation/NSSet.h>
|
||||||
#import <Foundation/NSUserDefaults.h>
|
#import <Foundation/NSUserDefaults.h>
|
||||||
#import <Foundation/NSValue.h>
|
#import <Foundation/NSValue.h>
|
||||||
|
|
||||||
|
|
|
@ -1003,7 +1003,7 @@ static float buttonsOffset = 1.0; // buttonsWidth = sw - 2*buttonsOffset
|
||||||
[theCell highlight: YES withFrame: rect inView: self];
|
[theCell highlight: YES withFrame: rect inView: self];
|
||||||
[_window flushWindow];
|
[_window flushWindow];
|
||||||
|
|
||||||
NSDebugLog (@"tracking cell %x", theCell);
|
NSDebugLog (@"tracking cell %@", theCell);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The "tracking" in this method actually takes place within
|
* The "tracking" in this method actually takes place within
|
||||||
|
|
|
@ -36,6 +36,7 @@
|
||||||
#include <Foundation/NSCoder.h>
|
#include <Foundation/NSCoder.h>
|
||||||
#include <Foundation/NSDecimalNumber.h>
|
#include <Foundation/NSDecimalNumber.h>
|
||||||
#include <Foundation/NSDebug.h>
|
#include <Foundation/NSDebug.h>
|
||||||
|
#include <Foundation/NSDictionary.h>
|
||||||
#include <Foundation/NSException.h>
|
#include <Foundation/NSException.h>
|
||||||
#include <Foundation/NSGeometry.h>
|
#include <Foundation/NSGeometry.h>
|
||||||
#include <Foundation/NSNotification.h>
|
#include <Foundation/NSNotification.h>
|
||||||
|
|
|
@ -93,9 +93,9 @@ typedef struct _tableViewFlags
|
||||||
unsigned int emptySelection:1;
|
unsigned int emptySelection:1;
|
||||||
unsigned int multipleSelection:1;
|
unsigned int multipleSelection:1;
|
||||||
unsigned int columnSelection:1;
|
unsigned int columnSelection:1;
|
||||||
unsigned int __unused:26;
|
unsigned int _unused:26;
|
||||||
#else
|
#else
|
||||||
unsigned int __unused:26;
|
unsigned int _unused:26;
|
||||||
unsigned int columnSelection:1;
|
unsigned int columnSelection:1;
|
||||||
unsigned int multipleSelection:1;
|
unsigned int multipleSelection:1;
|
||||||
unsigned int emptySelection:1;
|
unsigned int emptySelection:1;
|
||||||
|
|
|
@ -1643,8 +1643,8 @@ inFileViewerRootedAtPath: (NSString*)rootFullpath
|
||||||
- (NSArray*) mountedLocalVolumePaths
|
- (NSArray*) mountedLocalVolumePaths
|
||||||
{
|
{
|
||||||
NSMutableArray *names;
|
NSMutableArray *names;
|
||||||
NSFileManager *mgr = [NSFileManager defaultManager];
|
|
||||||
#if defined(__MINGW32__)
|
#if defined(__MINGW32__)
|
||||||
|
NSFileManager *mgr = [NSFileManager defaultManager];
|
||||||
unsigned max = BUFSIZ;
|
unsigned max = BUFSIZ;
|
||||||
unichar buf[max];
|
unichar buf[max];
|
||||||
unichar *base = buf;
|
unichar *base = buf;
|
||||||
|
@ -1679,6 +1679,7 @@ inFileViewerRootedAtPath: (NSString*)rootFullpath
|
||||||
}
|
}
|
||||||
|
|
||||||
#elif defined(HAVE_GETMNTENT) && defined (MNT_MEMB)
|
#elif defined(HAVE_GETMNTENT) && defined (MNT_MEMB)
|
||||||
|
NSFileManager *mgr = [NSFileManager defaultManager];
|
||||||
FILE *fptr = fopen("/etc/mtab", "r");
|
FILE *fptr = fopen("/etc/mtab", "r");
|
||||||
struct mntent *m;
|
struct mntent *m;
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
|
|
||||||
#include <Foundation/Foundation.h>
|
#import <Foundation/Foundation.h>
|
||||||
#include "AppKit/AppKit.h"
|
#import "AppKit/AppKit.h"
|
||||||
|
#import "GNUstepGUI/GSFontInfo.h"
|
||||||
|
|
||||||
void __objc_gui_linking(void)
|
void __objc_gui_linking(void)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue