mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-22 13:10:59 +00:00
Replace some occurences of int with NSInteger
and unsigned with NSUInteger. This allows to recompile gui on 64 bit systems after the change to NSNotFound in base. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@34312 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
0a6beb65c6
commit
8ad4aa86c4
35 changed files with 248 additions and 214 deletions
34
ChangeLog
34
ChangeLog
|
@ -1,3 +1,37 @@
|
|||
2011-12-17 Fred Kiefer <FredKiefer@gmx.de>
|
||||
|
||||
* Headers/AppKit/NSSliderCell.h
|
||||
* Headers/AppKit/NSLevelIndicator.h
|
||||
* Headers/AppKit/NSButtonCell.h
|
||||
* Headers/AppKit/NSButton.h
|
||||
* Headers/AppKit/NSMenuItem.h
|
||||
* Headers/AppKit/NSLevelIndicatorCell.h
|
||||
* Headers/AppKit/NSSlider.h
|
||||
* Headers/AppKit/NSTabView.h
|
||||
* Headers/AppKit/NSCell.h
|
||||
* Source/NSSliderCell.m
|
||||
* Source/NSLevelIndicator.m
|
||||
* Source/NSButtonCell.m
|
||||
* Source/NSButton.m
|
||||
* Source/NSMenu.m
|
||||
* Source/NSMenuItem.m
|
||||
* Source/NSLevelIndicatorCell.m
|
||||
* Source/GSToolbarView.m
|
||||
* Source/NSComboBoxCell.m
|
||||
* Source/NSToolbarItem.m
|
||||
* Source/NSSlider.m
|
||||
* Source/NSTabView.m
|
||||
* Source/NSCell.m
|
||||
* Source/NSWindow.m
|
||||
* Source/NSDocumentController.m
|
||||
* Source/NSTableView.m
|
||||
* Source/NSOutlineView.m
|
||||
* Source/NSParagraphStyle.m
|
||||
* Source/NSPopUpButtonCell.m
|
||||
* Source/NSView.m: Replace some occurences of int with NSInteger
|
||||
and unsigned with NSUInteger. This allows to recompile gui on 64
|
||||
bit systems after the change in base to NSNotFound.
|
||||
|
||||
2011-12-16 Riccardo Mottola <rm@gnu.org>
|
||||
|
||||
* Panels/English.lproj/GSPrintPanel.gorm
|
||||
|
|
|
@ -110,7 +110,7 @@
|
|||
NSColor *c = [color colorUsingColorSpaceName: NSNamedColorSpace];
|
||||
NSString *list;
|
||||
NSString *name;
|
||||
unsigned int index;
|
||||
NSUInteger index;
|
||||
|
||||
if (c == nil)
|
||||
return;
|
||||
|
|
|
@ -49,15 +49,15 @@
|
|||
//
|
||||
- (void)setButtonType:(NSButtonType)aType;
|
||||
#if OS_API_VERSION(GS_API_MACOSX, GS_API_LATEST)
|
||||
- (void)setHighlightsBy:(int)aType;
|
||||
- (void)setShowsStateBy:(int)aType;
|
||||
- (void)setHighlightsBy:(NSInteger)aType;
|
||||
- (void)setShowsStateBy:(NSInteger)aType;
|
||||
#endif
|
||||
|
||||
//
|
||||
// Setting the State
|
||||
//
|
||||
- (void)setState:(int)value;
|
||||
- (int)state;
|
||||
- (void)setState:(NSInteger)value;
|
||||
- (NSInteger)state;
|
||||
- (BOOL)allowsMixedState;
|
||||
- (void)setAllowsMixedState: (BOOL)flag;
|
||||
- (void)setNextState;
|
||||
|
@ -118,9 +118,9 @@
|
|||
// Setting the Key Equivalent
|
||||
//
|
||||
- (NSString *)keyEquivalent;
|
||||
- (unsigned int)keyEquivalentModifierMask;
|
||||
- (NSUInteger)keyEquivalentModifierMask;
|
||||
- (void)setKeyEquivalent:(NSString *)aKeyEquivalent;
|
||||
- (void)setKeyEquivalentModifierMask:(unsigned int)mask;
|
||||
- (void)setKeyEquivalentModifierMask:(NSUInteger)mask;
|
||||
|
||||
//
|
||||
// Handling Events and Action Messages
|
||||
|
|
|
@ -123,9 +123,9 @@ typedef enum _NSGradientType {
|
|||
NSString *_keyEquivalent;
|
||||
NSFont *_keyEquivalentFont;
|
||||
NSSound *_sound;
|
||||
unsigned int _keyEquivalentModifierMask;
|
||||
unsigned int _highlightsByMask;
|
||||
unsigned int _showAltStateMask;
|
||||
NSUInteger _keyEquivalentModifierMask;
|
||||
NSInteger _highlightsByMask;
|
||||
NSInteger _showAltStateMask;
|
||||
float _delayInterval;
|
||||
float _repeatInterval;
|
||||
NSBezelStyle _bezel_style;
|
||||
|
@ -154,8 +154,8 @@ typedef enum _NSGradientType {
|
|||
- (void)setAttributedTitle: (NSAttributedString *)aString;
|
||||
- (void)setTitleWithMnemonic: (NSString *)aString;
|
||||
- (NSString *)alternateMnemonic;
|
||||
- (unsigned)alternateMnemonicLocation;
|
||||
- (void)setAlternateMnemonicLocation: (unsigned)location;
|
||||
- (NSUInteger)alternateMnemonicLocation;
|
||||
- (void)setAlternateMnemonicLocation: (NSUInteger)location;
|
||||
- (void)setAlternateTitleWithMnemonic: (NSString *)aString;
|
||||
#endif
|
||||
|
||||
|
@ -184,9 +184,9 @@ typedef enum _NSGradientType {
|
|||
//
|
||||
- (NSString *)keyEquivalent;
|
||||
- (NSFont *)keyEquivalentFont;
|
||||
- (unsigned int)keyEquivalentModifierMask;
|
||||
- (NSUInteger)keyEquivalentModifierMask;
|
||||
- (void)setKeyEquivalent: (NSString *)key;
|
||||
- (void)setKeyEquivalentModifierMask: (unsigned int)mask;
|
||||
- (void)setKeyEquivalentModifierMask: (NSUInteger)mask;
|
||||
- (void)setKeyEquivalentFont: (NSFont *)fontObj;
|
||||
- (void)setKeyEquivalentFont: (NSString *)fontName
|
||||
size: (float)fontSize;
|
||||
|
@ -221,11 +221,11 @@ typedef enum _NSGradientType {
|
|||
//
|
||||
// Modifying Graphic Attributes
|
||||
//
|
||||
- (int)highlightsBy;
|
||||
- (void)setHighlightsBy: (int)mask;
|
||||
- (void)setShowsStateBy: (int)mask;
|
||||
- (NSInteger)highlightsBy;
|
||||
- (void)setHighlightsBy: (NSInteger)mask;
|
||||
- (void)setShowsStateBy: (NSInteger)mask;
|
||||
- (void)setButtonType: (NSButtonType)buttonType;
|
||||
- (int)showsStateBy;
|
||||
- (NSInteger)showsStateBy;
|
||||
|
||||
//
|
||||
// Sound
|
||||
|
|
|
@ -267,11 +267,11 @@ typedef enum {
|
|||
//
|
||||
// Setting the NSCell's State
|
||||
//
|
||||
- (void)setState:(int)value;
|
||||
- (int)state;
|
||||
- (void)setState:(NSInteger)value;
|
||||
- (NSInteger)state;
|
||||
- (BOOL)allowsMixedState;
|
||||
- (void)setAllowsMixedState:(BOOL)flag;
|
||||
- (int)nextState;
|
||||
- (NSInteger)nextState;
|
||||
- (void)setNextState;
|
||||
|
||||
//
|
||||
|
@ -378,8 +378,8 @@ typedef enum {
|
|||
- (BOOL)showsFirstResponder;
|
||||
- (void)setTitleWithMnemonic:(NSString *)aString;
|
||||
- (NSString *)mnemonic;
|
||||
- (void)setMnemonicLocation:(unsigned int)location;
|
||||
- (unsigned int)mnemonicLocation;
|
||||
- (void)setMnemonicLocation:(NSUInteger)location;
|
||||
- (NSUInteger)mnemonicLocation;
|
||||
- (BOOL)refusesFirstResponder;
|
||||
- (void)setRefusesFirstResponder:(BOOL)flag;
|
||||
|
||||
|
|
|
@ -49,14 +49,14 @@
|
|||
- (double) criticalValue;
|
||||
- (void) setCriticalValue: (double) val;
|
||||
|
||||
- (int) numberOfMajorTickMarks;
|
||||
- (int) numberOfTickMarks;
|
||||
- (NSRect) rectOfTickMarkAtIndex: (int)index;
|
||||
- (void) setNumberOfMajorTickMarks: (int)count;
|
||||
- (void) setNumberOfTickMarks: (int)count;
|
||||
- (NSInteger) numberOfMajorTickMarks;
|
||||
- (NSInteger) numberOfTickMarks;
|
||||
- (NSRect) rectOfTickMarkAtIndex: (NSInteger)index;
|
||||
- (void) setNumberOfMajorTickMarks: (NSInteger)count;
|
||||
- (void) setNumberOfTickMarks: (NSInteger)count;
|
||||
- (void) setTickMarkPosition: (NSTickMarkPosition)pos;
|
||||
- (NSTickMarkPosition) tickMarkPosition;
|
||||
- (double) tickMarkValueAtIndex: (int)index;
|
||||
- (double) tickMarkValueAtIndex: (NSInteger)index;
|
||||
|
||||
@end
|
||||
|
||||
|
|
|
@ -50,8 +50,8 @@ typedef enum _NSLevelIndicatorStyle
|
|||
double _maxValue;
|
||||
double _warningValue;
|
||||
double _criticalValue;
|
||||
int _numberOfMajorTickMarks;
|
||||
int _numberOfTickMarks;
|
||||
NSInteger _numberOfMajorTickMarks;
|
||||
NSInteger _numberOfTickMarks;
|
||||
NSLevelIndicatorStyle _style;
|
||||
NSTickMarkPosition _tickMarkPosition;
|
||||
NSRect _cellFrame;
|
||||
|
@ -72,14 +72,14 @@ typedef enum _NSLevelIndicatorStyle
|
|||
|
||||
- (NSLevelIndicatorStyle)style;
|
||||
- (void)setLevelIndicatorStyle:(NSLevelIndicatorStyle)style;
|
||||
- (int)numberOfMajorTickMarks;
|
||||
- (void)setNumberOfMajorTickMarks:(int)count;
|
||||
- (int)numberOfTickMarks;
|
||||
- (void)setNumberOfTickMarks:(int)count;
|
||||
- (NSInteger)numberOfMajorTickMarks;
|
||||
- (void)setNumberOfMajorTickMarks:(NSInteger)count;
|
||||
- (NSInteger)numberOfTickMarks;
|
||||
- (void)setNumberOfTickMarks:(NSInteger)count;
|
||||
- (NSTickMarkPosition)tickMarkPosition;
|
||||
- (void)setTickMarkPosition:(NSTickMarkPosition) pos;
|
||||
- (double)tickMarkValueAtIndex:(int)index;
|
||||
- (NSRect)rectOfTickMarkAtIndex:(int)index;
|
||||
- (double)tickMarkValueAtIndex:(NSInteger)index;
|
||||
- (NSRect)rectOfTickMarkAtIndex:(NSInteger)index;
|
||||
|
||||
@end
|
||||
|
||||
|
|
|
@ -152,7 +152,7 @@
|
|||
Returns the key equivalent mask.
|
||||
</p>
|
||||
*/
|
||||
- (unsigned int) keyEquivalentModifierMask;
|
||||
- (NSUInteger) keyEquivalentModifierMask;
|
||||
|
||||
/**
|
||||
<p>
|
||||
|
@ -168,7 +168,7 @@
|
|||
*/
|
||||
- (NSImage*) mixedStateImage;
|
||||
- (NSString*) mnemonic;
|
||||
- (unsigned) mnemonicLocation;
|
||||
- (NSUInteger) mnemonicLocation;
|
||||
|
||||
/**
|
||||
<p>
|
||||
|
@ -235,7 +235,7 @@
|
|||
key equivalent requires ALT, Control or other key modifiers.
|
||||
</p>
|
||||
*/
|
||||
- (void) setKeyEquivalentModifierMask: (unsigned int)mask;
|
||||
- (void) setKeyEquivalentModifierMask: (NSUInteger)mask;
|
||||
|
||||
/**
|
||||
<p> Sets the menu which this item belongs to. This method does not retain the
|
||||
|
@ -250,7 +250,7 @@
|
|||
</p>
|
||||
*/
|
||||
- (void) setMixedStateImage: (NSImage*)image;
|
||||
- (void) setMnemonicLocation: (unsigned) location;
|
||||
- (void) setMnemonicLocation: (NSUInteger) location;
|
||||
|
||||
/**
|
||||
<p>
|
||||
|
@ -278,7 +278,7 @@
|
|||
Sets the state of the the receiver.
|
||||
</p>
|
||||
*/
|
||||
- (void) setState: (int)state;
|
||||
- (void) setState: (NSInteger)state;
|
||||
|
||||
/**
|
||||
<p>
|
||||
|
@ -319,7 +319,7 @@
|
|||
Returns the state of the receiver.
|
||||
</p>
|
||||
*/
|
||||
- (int) state;
|
||||
- (NSInteger) state;
|
||||
/**
|
||||
<p>
|
||||
Returns the attached submenu.
|
||||
|
@ -357,7 +357,7 @@
|
|||
Returns the user defined key equivalent modifier.
|
||||
</p>
|
||||
*/
|
||||
- (unsigned int) userKeyEquivalentModifierMask;
|
||||
- (NSUInteger) userKeyEquivalentModifierMask;
|
||||
|
||||
/**
|
||||
<p>
|
||||
|
@ -373,16 +373,16 @@
|
|||
NSMenu *_menu;
|
||||
NSString *_title;
|
||||
NSString *_keyEquivalent;
|
||||
unsigned int _keyEquivalentModifierMask;
|
||||
unsigned _mnemonicLocation;
|
||||
int _state;
|
||||
NSUInteger _keyEquivalentModifierMask;
|
||||
NSUInteger _mnemonicLocation;
|
||||
NSInteger _state;
|
||||
NSImage *_image;
|
||||
NSImage *_onStateImage;
|
||||
NSImage *_offStateImage;
|
||||
NSImage *_mixedStateImage;
|
||||
id _target;
|
||||
SEL _action;
|
||||
int _tag;
|
||||
NSInteger _tag;
|
||||
id _representedObject;
|
||||
NSMenu *_submenu;
|
||||
BOOL _enabled;
|
||||
|
|
|
@ -71,14 +71,14 @@
|
|||
// ticks
|
||||
- (BOOL) allowsTickMarkValuesOnly;
|
||||
- (double) closestTickMarkValueToValue: (double)aValue;
|
||||
- (int) indexOfTickMarkAtPoint: (NSPoint)point;
|
||||
- (int) numberOfTickMarks;
|
||||
- (NSRect) rectOfTickMarkAtIndex: (int)index;
|
||||
- (NSInteger) indexOfTickMarkAtPoint: (NSPoint)point;
|
||||
- (NSInteger) numberOfTickMarks;
|
||||
- (NSRect) rectOfTickMarkAtIndex: (NSInteger)index;
|
||||
- (void) setAllowsTickMarkValuesOnly: (BOOL)flag;
|
||||
- (void) setNumberOfTickMarks: (int)numberOfTickMarks;
|
||||
- (void) setNumberOfTickMarks: (NSInteger)numberOfTickMarks;
|
||||
- (void) setTickMarkPosition: (NSTickMarkPosition)position;
|
||||
- (NSTickMarkPosition) tickMarkPosition;
|
||||
- (double) tickMarkValueAtIndex: (int)index;
|
||||
- (double) tickMarkValueAtIndex: (NSInteger)index;
|
||||
#endif
|
||||
|
||||
@end
|
||||
|
|
|
@ -59,7 +59,7 @@ typedef enum _NSSliderType
|
|||
NSRect _trackRect;
|
||||
BOOL _isVertical;
|
||||
BOOL _allowsTickMarkValuesOnly;
|
||||
int _numberOfTickMarks;
|
||||
NSInteger _numberOfTickMarks;
|
||||
NSTickMarkPosition _tickMarkPosition;
|
||||
NSSliderType _type;
|
||||
}
|
||||
|
@ -107,14 +107,14 @@ typedef enum _NSSliderType
|
|||
// ticks
|
||||
- (BOOL) allowsTickMarkValuesOnly;
|
||||
- (double) closestTickMarkValueToValue: (double)aValue;
|
||||
- (int) indexOfTickMarkAtPoint: (NSPoint)point;
|
||||
- (int) numberOfTickMarks;
|
||||
- (NSRect) rectOfTickMarkAtIndex: (int)index;
|
||||
- (NSInteger) indexOfTickMarkAtPoint: (NSPoint)point;
|
||||
- (NSInteger) numberOfTickMarks;
|
||||
- (NSRect) rectOfTickMarkAtIndex: (NSInteger)index;
|
||||
- (void) setAllowsTickMarkValuesOnly: (BOOL)flag;
|
||||
- (void) setNumberOfTickMarks: (int)numberOfTickMarks;
|
||||
- (void) setNumberOfTickMarks: (NSInteger)numberOfTickMarks;
|
||||
- (void) setTickMarkPosition: (NSTickMarkPosition)position;
|
||||
- (NSTickMarkPosition) tickMarkPosition;
|
||||
- (double) tickMarkValueAtIndex: (int)index;
|
||||
- (double) tickMarkValueAtIndex: (NSInteger)index;
|
||||
#endif
|
||||
|
||||
@end
|
||||
|
|
|
@ -54,17 +54,17 @@ typedef enum {
|
|||
BOOL _draws_background;
|
||||
BOOL _truncated_label;
|
||||
id _delegate;
|
||||
int _selected_item;
|
||||
NSInteger _selected_item;
|
||||
}
|
||||
- (void)addTabViewItem:(NSTabViewItem *)tabViewItem;
|
||||
- (void)insertTabViewItem:(NSTabViewItem *)tabViewItem
|
||||
atIndex:(int)index;
|
||||
atIndex:(NSInteger)index;
|
||||
- (void)removeTabViewItem:(NSTabViewItem *)tabViewItem;
|
||||
- (int)indexOfTabViewItem:(NSTabViewItem *)tabViewItem;
|
||||
- (int)indexOfTabViewItemWithIdentifier:(id)identifier;
|
||||
- (int)numberOfTabViewItems;
|
||||
- (NSInteger)indexOfTabViewItem:(NSTabViewItem *)tabViewItem;
|
||||
- (NSInteger)indexOfTabViewItemWithIdentifier:(id)identifier;
|
||||
- (NSInteger)numberOfTabViewItems;
|
||||
|
||||
- (NSTabViewItem *)tabViewItemAtIndex:(int)index;
|
||||
- (NSTabViewItem *)tabViewItemAtIndex:(NSInteger)index;
|
||||
- (NSArray *)tabViewItems;
|
||||
|
||||
- (void)selectFirstTabViewItem:(id)sender;
|
||||
|
@ -72,7 +72,7 @@ typedef enum {
|
|||
- (void)selectNextTabViewItem:(id)sender;
|
||||
- (void)selectPreviousTabViewItem:(id)sender;
|
||||
- (void)selectTabViewItem:(NSTabViewItem *)tabViewItem;
|
||||
- (void)selectTabViewItemAtIndex:(int)index;
|
||||
- (void)selectTabViewItemAtIndex:(NSInteger)index;
|
||||
- (void)selectTabViewItemWithIdentifier:(id)identifier;
|
||||
- (void)takeSelectedTabViewItemFromSender:(id)sender;
|
||||
- (NSTabViewItem*) selectedTabViewItem;
|
||||
|
|
|
@ -1604,7 +1604,7 @@ static BOOL _isInInterfaceBuilder = NO;
|
|||
- (void) instantiateWithInstantiator: (id<GSInstantiator>)instantiator
|
||||
{
|
||||
NSRange colonRange = [_tag rangeOfString: @":"];
|
||||
unsigned int location = colonRange.location;
|
||||
NSUInteger location = colonRange.location;
|
||||
|
||||
if (location == NSNotFound)
|
||||
{
|
||||
|
@ -2024,7 +2024,7 @@ static BOOL _isInInterfaceBuilder = NO;
|
|||
{
|
||||
NSArray *nameKeys = (NSArray *)NSAllMapTableKeys(_names);
|
||||
NSArray *nameValues = (NSArray *)NSAllMapTableValues(_names);
|
||||
int i = [nameValues indexOfObject: name];
|
||||
NSUInteger i = [nameValues indexOfObject: name];
|
||||
id result = nil;
|
||||
|
||||
if (i != NSNotFound)
|
||||
|
|
|
@ -556,7 +556,7 @@ typedef struct {
|
|||
forName: @"GSThemeDomain"];
|
||||
if ([searchList containsObject: @"GSThemeDomain"] == NO)
|
||||
{
|
||||
unsigned index;
|
||||
NSUInteger index;
|
||||
|
||||
/*
|
||||
* Higher priority than GSConfigDomain and NSRegistrationDomain,
|
||||
|
|
|
@ -2498,9 +2498,9 @@ static NSDictionary *titleTextAttributes[3] = {nil, nil, nil};
|
|||
|
||||
if (selectingColumns == NO)
|
||||
{
|
||||
int selectedRowsCount;
|
||||
int row;
|
||||
int startingRow, endingRow;
|
||||
NSInteger selectedRowsCount;
|
||||
NSUInteger row;
|
||||
NSInteger startingRow, endingRow;
|
||||
|
||||
selectedRowsCount = [selectedRows count];
|
||||
if (selectedRowsCount == 0)
|
||||
|
@ -2542,9 +2542,9 @@ static NSDictionary *titleTextAttributes[3] = {nil, nil, nil};
|
|||
}
|
||||
else // Selecting columns
|
||||
{
|
||||
unsigned int selectedColumnsCount;
|
||||
unsigned int column;
|
||||
int startingColumn, endingColumn;
|
||||
NSUInteger selectedColumnsCount;
|
||||
NSUInteger column;
|
||||
NSInteger startingColumn, endingColumn;
|
||||
|
||||
selectedColumnsCount = [selectedColumns count];
|
||||
|
||||
|
|
|
@ -66,7 +66,7 @@ static const int ClippedItemsViewWidth = 28;
|
|||
// Internal
|
||||
static const int current_version = 1;
|
||||
|
||||
static int draggedItemIndex = NSNotFound;
|
||||
static NSInteger draggedItemIndex = NSNotFound;
|
||||
|
||||
/*
|
||||
* Toolbar related code
|
||||
|
@ -341,7 +341,7 @@ static int draggedItemIndex = NSNotFound;
|
|||
if (![item allowsDuplicatesInToolbar])
|
||||
{
|
||||
NSArray *items = [toolbar items];
|
||||
int index;
|
||||
NSInteger index;
|
||||
for (index=0; index<[items count]; index++)
|
||||
{
|
||||
NSToolbarItem *anItem = [items objectAtIndex:index];
|
||||
|
|
|
@ -234,10 +234,10 @@
|
|||
{
|
||||
NSString *tag = [self label];
|
||||
NSRange colonRange = [tag rangeOfString: @":"];
|
||||
unsigned int location = colonRange.location;
|
||||
NSUInteger location = colonRange.location;
|
||||
NSNibConnector *result = nil;
|
||||
|
||||
if(location == NSNotFound)
|
||||
if (location == NSNotFound)
|
||||
{
|
||||
result = [[NSNibOutletConnector alloc] init];
|
||||
}
|
||||
|
|
|
@ -99,12 +99,12 @@ static id buttonCellClass = nil;
|
|||
[self setNeedsDisplay: YES];
|
||||
}
|
||||
|
||||
- (void)setHighlightsBy:(int)aType
|
||||
- (void)setHighlightsBy:(NSInteger)aType
|
||||
{
|
||||
[_cell setHighlightsBy:aType];
|
||||
}
|
||||
|
||||
- (void)setShowsStateBy:(int)aType
|
||||
- (void)setShowsStateBy:(NSInteger)aType
|
||||
{
|
||||
[_cell setShowsStateBy:aType];
|
||||
}
|
||||
|
@ -130,7 +130,7 @@ static id buttonCellClass = nil;
|
|||
/**<p>Sets the NSButtonCell's state to <var>value</var> and marks
|
||||
self for display.</p><p>See Also: -state [NSButtonCell-setState:]</p>
|
||||
*/
|
||||
- (void) setState: (int)value
|
||||
- (void) setState: (NSInteger)value
|
||||
{
|
||||
[_cell setState: value];
|
||||
[self setNeedsDisplay: YES];
|
||||
|
@ -139,7 +139,7 @@ static id buttonCellClass = nil;
|
|||
/** <p>Returns the NSButtonCell's state.</p>
|
||||
<p>See Also: -setState: [NSButtonCell-state]</p>
|
||||
*/
|
||||
- (int) state
|
||||
- (NSInteger) state
|
||||
{
|
||||
return [_cell state];
|
||||
}
|
||||
|
@ -410,7 +410,7 @@ static id buttonCellClass = nil;
|
|||
NSCommandKeyMask.</p><p>See Also: -setKeyEquivalentModifierMask:
|
||||
-keyEquivalent [NSButtonCell-setKeyEquivalentModifierMask:]</p>
|
||||
*/
|
||||
- (unsigned int) keyEquivalentModifierMask
|
||||
- (NSUInteger) keyEquivalentModifierMask
|
||||
{
|
||||
return [_cell keyEquivalentModifierMask];
|
||||
}
|
||||
|
@ -434,7 +434,7 @@ static id buttonCellClass = nil;
|
|||
-setKeyEquivalent: -performKeyEquivalent:
|
||||
[NSButtonCell-setKeyEquivalentModifierMask:]</p>
|
||||
*/
|
||||
- (void) setKeyEquivalentModifierMask: (unsigned int)mask
|
||||
- (void) setKeyEquivalentModifierMask: (NSUInteger)mask
|
||||
{
|
||||
[_cell setKeyEquivalentModifierMask: mask];
|
||||
}
|
||||
|
@ -515,9 +515,9 @@ static id buttonCellClass = nil;
|
|||
|
||||
if ([keyEquivalent length] > 0 && [keyEquivalent isEqualToString: [anEvent charactersIgnoringModifiers]])
|
||||
{
|
||||
unsigned int mask = [self keyEquivalentModifierMask];
|
||||
unsigned int modifiers = [anEvent modifierFlags];
|
||||
unsigned int relevantModifiersMask = NSCommandKeyMask | NSAlternateKeyMask | NSControlKeyMask;
|
||||
NSUInteger mask = [self keyEquivalentModifierMask];
|
||||
NSUInteger modifiers = [anEvent modifierFlags];
|
||||
NSUInteger relevantModifiersMask = NSCommandKeyMask | NSAlternateKeyMask | NSControlKeyMask;
|
||||
/* Take shift key into account only for control keys and arrow and function keys */
|
||||
if ((modifiers & NSFunctionKeyMask)
|
||||
|| [[NSCharacterSet controlCharacterSet] characterIsMember:[keyEquivalent characterAtIndex:0]])
|
||||
|
|
|
@ -449,20 +449,20 @@ typedef struct _GSButtonCellFlags
|
|||
return @"";
|
||||
}
|
||||
|
||||
- (unsigned)alternateMnemonicLocation
|
||||
- (NSUInteger)alternateMnemonicLocation
|
||||
{
|
||||
// TODO
|
||||
return NSNotFound;
|
||||
}
|
||||
|
||||
- (void)setAlternateMnemonicLocation:(unsigned)location
|
||||
- (void)setAlternateMnemonicLocation:(NSUInteger)location
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
- (void)setAlternateTitleWithMnemonic:(NSString *)aString
|
||||
{
|
||||
unsigned int location = [aString rangeOfString: @"&"].location;
|
||||
NSUInteger location = [aString rangeOfString: @"&"].location;
|
||||
|
||||
[self setAlternateTitle: [aString stringByReplacingString: @"&"
|
||||
withString: @""]];
|
||||
|
@ -616,7 +616,7 @@ typedef struct _GSButtonCellFlags
|
|||
0.</p><p>See Also: -setKeyEquivalentModifierMask:
|
||||
-keyEquivalent [NSButton-performKeyEquivalent:]</p>
|
||||
*/
|
||||
- (unsigned int) keyEquivalentModifierMask
|
||||
- (NSUInteger) keyEquivalentModifierMask
|
||||
{
|
||||
return _keyEquivalentModifierMask;
|
||||
}
|
||||
|
@ -639,7 +639,7 @@ typedef struct _GSButtonCellFlags
|
|||
<p>See Also: -keyEquivalentModifierMask
|
||||
-setKeyEquivalent: [NSButton-performKeyEquivalent:]</p>
|
||||
*/
|
||||
- (void) setKeyEquivalentModifierMask: (unsigned int)mask
|
||||
- (void) setKeyEquivalentModifierMask: (NSUInteger)mask
|
||||
{
|
||||
_keyEquivalentModifierMask = mask;
|
||||
}
|
||||
|
@ -738,7 +738,7 @@ typedef struct _GSButtonCellFlags
|
|||
NSChangeBackgroundCellMask</p>
|
||||
<p>See Also : -setHighlightsBy:</p>
|
||||
*/
|
||||
- (int) highlightsBy
|
||||
- (NSInteger) highlightsBy
|
||||
{
|
||||
return _highlightsByMask;
|
||||
}
|
||||
|
@ -748,12 +748,12 @@ typedef struct _GSButtonCellFlags
|
|||
NSChangeBackgroundCellMask</p>
|
||||
<p>See Also : -highlightsBy</p>
|
||||
*/
|
||||
- (void) setHighlightsBy: (int)mask
|
||||
- (void) setHighlightsBy: (NSInteger)mask
|
||||
{
|
||||
_highlightsByMask = mask;
|
||||
}
|
||||
|
||||
- (void) setShowsStateBy: (int)mask
|
||||
- (void) setShowsStateBy: (NSInteger)mask
|
||||
{
|
||||
_showAltStateMask = mask;
|
||||
}
|
||||
|
@ -819,7 +819,7 @@ typedef struct _GSButtonCellFlags
|
|||
}
|
||||
}
|
||||
|
||||
- (int) showsStateBy
|
||||
- (NSInteger) showsStateBy
|
||||
{
|
||||
return _showAltStateMask;
|
||||
}
|
||||
|
|
|
@ -779,7 +779,7 @@ static NSColor *dtxtCol;
|
|||
implementation. (Currently they match the Cocoa values but they are
|
||||
quite strange)</p> <p>See Also: -state</p>
|
||||
*/
|
||||
- (void) setState: (int)value
|
||||
- (void) setState: (NSInteger)value
|
||||
{
|
||||
/* We do exactly as in macosx when value is not NSOnState,
|
||||
* NSOffState, NSMixedState, even if their behaviour (value < 0 ==>
|
||||
|
@ -804,7 +804,7 @@ static NSColor *dtxtCol;
|
|||
/**<p>Returns the NSCell's state</p>
|
||||
<p>See Also: -setState: </p>
|
||||
*/
|
||||
- (int) state
|
||||
- (NSInteger) state
|
||||
{
|
||||
return _cell.state;
|
||||
}
|
||||
|
@ -823,7 +823,7 @@ static NSColor *dtxtCol;
|
|||
}
|
||||
}
|
||||
|
||||
- (int) nextState
|
||||
- (NSInteger) nextState
|
||||
{
|
||||
switch (_cell.state)
|
||||
{
|
||||
|
@ -1390,7 +1390,7 @@ static NSColor *dtxtCol;
|
|||
|
||||
- (NSString*) mnemonic
|
||||
{
|
||||
unsigned int location = [self mnemonicLocation];
|
||||
NSUInteger location = [self mnemonicLocation];
|
||||
NSString *c = [self title];
|
||||
|
||||
if ((location == NSNotFound) || location >= [c length])
|
||||
|
@ -1399,12 +1399,12 @@ static NSColor *dtxtCol;
|
|||
return [c substringWithRange: NSMakeRange (location, 1)];
|
||||
}
|
||||
|
||||
- (void) setMnemonicLocation: (unsigned int)location
|
||||
- (void) setMnemonicLocation: (NSUInteger)location
|
||||
{
|
||||
_cell.mnemonic_location = location;
|
||||
}
|
||||
|
||||
- (unsigned int) mnemonicLocation
|
||||
- (NSUInteger) mnemonicLocation
|
||||
{
|
||||
return _cell.mnemonic_location;
|
||||
}
|
||||
|
|
|
@ -1095,7 +1095,7 @@ static GSComboWindow *gsWindow = nil;
|
|||
}
|
||||
else
|
||||
{
|
||||
int i = [_popUpList indexOfObject: object];
|
||||
NSInteger i = [_popUpList indexOfObject: object];
|
||||
|
||||
if (i == NSNotFound)
|
||||
i = -1;
|
||||
|
@ -1850,7 +1850,7 @@ static inline NSRect buttonCellFrameFromRect(NSRect cellRect)
|
|||
- (void) _selectCompleted
|
||||
{
|
||||
NSString *more;
|
||||
unsigned int index = NSNotFound;
|
||||
NSUInteger index = NSNotFound;
|
||||
|
||||
more = [self completedString: [self stringValue]];
|
||||
if (_usesDataSource)
|
||||
|
|
|
@ -1346,7 +1346,7 @@ static BOOL _shouldClose = YES;
|
|||
|
||||
- (void) noteNewRecentDocumentURL: (NSURL *)anURL
|
||||
{
|
||||
unsigned index = [_recent_documents indexOfObject: anURL];
|
||||
NSUInteger index = [_recent_documents indexOfObject: anURL];
|
||||
NSMutableArray *a;
|
||||
|
||||
if (index != NSNotFound)
|
||||
|
|
|
@ -103,22 +103,22 @@ static Class cellClass;
|
|||
[_cell setCriticalValue: val];
|
||||
}
|
||||
|
||||
- (int) numberOfMajorTickMarks
|
||||
- (NSInteger) numberOfMajorTickMarks
|
||||
{
|
||||
return [_cell numberOfMajorTickMarks];
|
||||
}
|
||||
|
||||
- (void) setNumberOfMajorTickMarks: (int)count
|
||||
- (void) setNumberOfMajorTickMarks: (NSInteger)count
|
||||
{
|
||||
[_cell setNumberOfMajorTickMarks: count];
|
||||
}
|
||||
|
||||
- (int) numberOfTickMarks
|
||||
- (NSInteger) numberOfTickMarks
|
||||
{
|
||||
return [_cell numberOfTickMarks];
|
||||
}
|
||||
|
||||
- (void) setNumberOfTickMarks: (int)count
|
||||
- (void) setNumberOfTickMarks: (NSInteger)count
|
||||
{
|
||||
[_cell setNumberOfTickMarks: count];
|
||||
}
|
||||
|
@ -133,12 +133,12 @@ static Class cellClass;
|
|||
[_cell setTickMarkPosition:pos];
|
||||
}
|
||||
|
||||
- (double) tickMarkValueAtIndex: (int)index
|
||||
- (double) tickMarkValueAtIndex: (NSInteger)index
|
||||
{
|
||||
return [_cell tickMarkValueAtIndex:index];
|
||||
}
|
||||
|
||||
- (NSRect) rectOfTickMarkAtIndex: (int)index
|
||||
- (NSRect) rectOfTickMarkAtIndex: (NSInteger)index
|
||||
{
|
||||
return [_cell rectOfTickMarkAtIndex:index];
|
||||
}
|
||||
|
|
|
@ -127,22 +127,22 @@
|
|||
_style = style;
|
||||
}
|
||||
|
||||
- (int) numberOfMajorTickMarks
|
||||
- (NSInteger) numberOfMajorTickMarks
|
||||
{
|
||||
return _numberOfMajorTickMarks;
|
||||
}
|
||||
|
||||
- (void) setNumberOfMajorTickMarks: (int)count
|
||||
- (void) setNumberOfMajorTickMarks: (NSInteger)count
|
||||
{
|
||||
_numberOfMajorTickMarks = count;
|
||||
}
|
||||
|
||||
- (int) numberOfTickMarks
|
||||
- (NSInteger) numberOfTickMarks
|
||||
{
|
||||
return _numberOfTickMarks;
|
||||
}
|
||||
|
||||
- (void) setNumberOfTickMarks: (int)count
|
||||
- (void) setNumberOfTickMarks: (NSInteger)count
|
||||
{
|
||||
_numberOfTickMarks = count;
|
||||
}
|
||||
|
@ -157,7 +157,7 @@
|
|||
_tickMarkPosition = pos;
|
||||
}
|
||||
|
||||
- (double) tickMarkValueAtIndex: (int)index
|
||||
- (double) tickMarkValueAtIndex: (NSInteger)index
|
||||
{
|
||||
if ((index < 0) || (index >= _numberOfTickMarks))
|
||||
{
|
||||
|
@ -168,7 +168,7 @@
|
|||
return _minValue + index * (_maxValue - _minValue) / _numberOfTickMarks;
|
||||
}
|
||||
|
||||
- (NSRect) rectOfTickMarkAtIndex: (int)index
|
||||
- (NSRect) rectOfTickMarkAtIndex: (NSInteger)index
|
||||
{
|
||||
NSRect cellRect = NSZeroRect;
|
||||
float frameWidth = _cellFrame.size.width;
|
||||
|
@ -193,7 +193,7 @@
|
|||
// If major tick marks fit with even spacing
|
||||
else if ((_numberOfTickMarks -1) % (_numberOfMajorTickMarks - 1) == 0)
|
||||
{
|
||||
int minorTicksPerMajor = (_numberOfTickMarks - 1) / (_numberOfMajorTickMarks - 1);
|
||||
NSInteger minorTicksPerMajor = (_numberOfTickMarks - 1) / (_numberOfMajorTickMarks - 1);
|
||||
|
||||
// If index is a major tick mark
|
||||
if (index % minorTicksPerMajor == 0)
|
||||
|
|
|
@ -909,7 +909,7 @@ static BOOL menuBarVisible = YES;
|
|||
*/
|
||||
- (int) indexOfItem: (id <NSMenuItem>)anObject
|
||||
{
|
||||
int index;
|
||||
NSUInteger index;
|
||||
|
||||
index = [_items indexOfObjectIdenticalTo: anObject];
|
||||
|
||||
|
|
|
@ -163,7 +163,7 @@ static Class imageClass;
|
|||
if (userKeyEquivalent)
|
||||
{
|
||||
// check for leading symbols representing modifier flags: @, ~, $, ^
|
||||
unsigned int modifierMask = 0;
|
||||
NSUInteger modifierMask = 0;
|
||||
while ([userKeyEquivalent length] > 1)
|
||||
{
|
||||
if ([userKeyEquivalent hasPrefix:@"@"])
|
||||
|
@ -292,7 +292,7 @@ static Class imageClass;
|
|||
return _keyEquivalent;
|
||||
}
|
||||
|
||||
- (void) setKeyEquivalentModifierMask: (unsigned int)mask
|
||||
- (void) setKeyEquivalentModifierMask: (NSUInteger)mask
|
||||
{
|
||||
if (_keyEquivalentModifierMask == mask)
|
||||
return; // no change
|
||||
|
@ -300,7 +300,7 @@ static Class imageClass;
|
|||
[_menu itemChanged: self];
|
||||
}
|
||||
|
||||
- (unsigned int) keyEquivalentModifierMask
|
||||
- (NSUInteger) keyEquivalentModifierMask
|
||||
{
|
||||
return _keyEquivalentModifierMask;
|
||||
}
|
||||
|
@ -318,13 +318,13 @@ static Class imageClass;
|
|||
return userKeyEquivalent;
|
||||
}
|
||||
|
||||
- (unsigned int) userKeyEquivalentModifierMask
|
||||
- (NSUInteger) userKeyEquivalentModifierMask
|
||||
{
|
||||
// FIXME
|
||||
return NSCommandKeyMask;
|
||||
}
|
||||
|
||||
- (void) setMnemonicLocation: (unsigned)location
|
||||
- (void) setMnemonicLocation: (NSUInteger)location
|
||||
{
|
||||
if (_mnemonicLocation == location)
|
||||
return; // no change
|
||||
|
@ -333,7 +333,7 @@ static Class imageClass;
|
|||
[_menu itemChanged: self];
|
||||
}
|
||||
|
||||
- (unsigned) mnemonicLocation
|
||||
- (NSUInteger) mnemonicLocation
|
||||
{
|
||||
if (_mnemonicLocation != 255)
|
||||
return _mnemonicLocation;
|
||||
|
@ -351,7 +351,7 @@ static Class imageClass;
|
|||
|
||||
- (void) setTitleWithMnemonic: (NSString*)stringWithAmpersand
|
||||
{
|
||||
unsigned int location = [stringWithAmpersand rangeOfString: @"&"].location;
|
||||
NSUInteger location = [stringWithAmpersand rangeOfString: @"&"].location;
|
||||
|
||||
[self setTitle: [stringWithAmpersand stringByReplacingString: @"&"
|
||||
withString: @""]];
|
||||
|
@ -375,7 +375,7 @@ static Class imageClass;
|
|||
return _image;
|
||||
}
|
||||
|
||||
- (void) setState: (int)state
|
||||
- (void) setState: (NSInteger)state
|
||||
{
|
||||
if (_state == state)
|
||||
return;
|
||||
|
@ -385,7 +385,7 @@ static Class imageClass;
|
|||
[_menu itemChanged: self];
|
||||
}
|
||||
|
||||
- (int) state
|
||||
- (NSInteger) state
|
||||
{
|
||||
return _state;
|
||||
}
|
||||
|
|
|
@ -1497,9 +1497,9 @@ Also returns the child index relative to this parent. */
|
|||
if ([_dataSource respondsToSelector:
|
||||
@selector(outlineView:namesOfPromisedFilesDroppedAtDestination:forDraggedItems:)])
|
||||
{
|
||||
int count = [_selectedRows count];
|
||||
NSUInteger count = [_selectedRows count];
|
||||
NSMutableArray *itemArray = [NSMutableArray arrayWithCapacity: count];
|
||||
unsigned int index = [_selectedRows firstIndex];
|
||||
NSUInteger index = [_selectedRows firstIndex];
|
||||
|
||||
while (index != NSNotFound)
|
||||
{
|
||||
|
@ -1838,9 +1838,9 @@ Also returns the child index relative to this parent. */
|
|||
- (BOOL) _writeRows: (NSIndexSet *)rows
|
||||
toPasteboard: (NSPasteboard *)pboard
|
||||
{
|
||||
int count = [rows count];
|
||||
NSUInteger count = [rows count];
|
||||
NSMutableArray *itemArray = [NSMutableArray arrayWithCapacity: count];
|
||||
unsigned int index = [rows firstIndex];
|
||||
NSUInteger index = [rows firstIndex];
|
||||
|
||||
while (index != NSNotFound)
|
||||
{
|
||||
|
@ -2049,7 +2049,7 @@ Also returns the child index relative to this parent. */
|
|||
|
||||
- (void)_closeItem: (id)item
|
||||
{
|
||||
int i, numChildren;
|
||||
NSUInteger i, numChildren;
|
||||
NSMutableArray *removeAll = [NSMutableArray array];
|
||||
|
||||
[self _collectItemsStartingWith: item into: removeAll];
|
||||
|
@ -2073,7 +2073,7 @@ Also returns the child index relative to this parent. */
|
|||
|
||||
- (void)_openItem: (id)item
|
||||
{
|
||||
int i, insertionPoint, numChildren, numDescendants;
|
||||
NSUInteger i, insertionPoint, numChildren, numDescendants;
|
||||
id object;
|
||||
id sitem = (item == nil) ? (id)[NSNull null] : (id)item;
|
||||
|
||||
|
@ -2110,7 +2110,7 @@ Also returns the child index relative to this parent. */
|
|||
// Add all of the children...
|
||||
if ([self isItemExpanded: child])
|
||||
{
|
||||
int i, numItems;
|
||||
NSUInteger i, numItems;
|
||||
NSMutableArray *insertAll = [NSMutableArray array];
|
||||
|
||||
[self _collectItemsStartingWith: child into: insertAll];
|
||||
|
@ -2132,7 +2132,7 @@ Also returns the child index relative to this parent. */
|
|||
|
||||
- (void) _removeChildren: (id)startitem
|
||||
{
|
||||
int i, numChildren;
|
||||
NSUInteger i, numChildren;
|
||||
id sitem = (startitem == nil) ? (id)[NSNull null] : (id)startitem;
|
||||
NSMutableArray *anarray;
|
||||
|
||||
|
@ -2154,7 +2154,7 @@ Also returns the child index relative to this parent. */
|
|||
- (void) _noteNumberOfRowsChangedBelowItem: (id)item by: (int)numItems
|
||||
{
|
||||
BOOL selectionDidChange = NO;
|
||||
int rowIndex, nextIndex;
|
||||
NSUInteger rowIndex, nextIndex;
|
||||
|
||||
// check for trivial case
|
||||
if (numItems == 0)
|
||||
|
@ -2206,8 +2206,8 @@ Also returns the child index relative to this parent. */
|
|||
/* If the item at _selectedRow was removed, we arbitrarily choose
|
||||
* another selected item (if there is still any). The policy
|
||||
* implemented below chooses the index most close to item. */
|
||||
int r1 = [_selectedRows indexLessThanIndex: rowIndex];
|
||||
int r2 = [_selectedRows indexGreaterThanOrEqualToIndex: rowIndex];
|
||||
NSUInteger r1 = [_selectedRows indexLessThanIndex: rowIndex];
|
||||
NSUInteger r2 = [_selectedRows indexGreaterThanOrEqualToIndex: rowIndex];
|
||||
if (r1 != NSNotFound && r2 != NSNotFound)
|
||||
{
|
||||
_selectedRow = (rowIndex - r1) <= (r2 - rowIndex) ? r1 : r2;
|
||||
|
|
|
@ -749,7 +749,7 @@ static NSParagraphStyle *defaultStyle = nil;
|
|||
|
||||
- (void) removeTabStop: (NSTextTab*)anObject
|
||||
{
|
||||
unsigned i = [_tabStops indexOfObject: anObject];
|
||||
NSUInteger i = [_tabStops indexOfObject: anObject];
|
||||
|
||||
if (i != NSNotFound)
|
||||
[_tabStops removeObjectAtIndex: i];
|
||||
|
|
|
@ -1342,7 +1342,7 @@ static NSImage *_pbc_image[5];
|
|||
- (void) _popUpItemAction: (id)sender
|
||||
{
|
||||
// first, if sender is one of our items, set it as our selected item
|
||||
int index = [_menu indexOfItem: sender];
|
||||
NSUInteger index = [_menu indexOfItem: sender];
|
||||
if (index != NSNotFound)
|
||||
[self selectItemAtIndex: index];
|
||||
|
||||
|
|
|
@ -365,17 +365,17 @@ static Class cellClass;
|
|||
return [_cell closestTickMarkValueToValue: aValue];
|
||||
}
|
||||
|
||||
- (int) indexOfTickMarkAtPoint: (NSPoint)point
|
||||
- (NSInteger) indexOfTickMarkAtPoint: (NSPoint)point
|
||||
{
|
||||
return [_cell indexOfTickMarkAtPoint: point];
|
||||
}
|
||||
|
||||
- (int) numberOfTickMarks
|
||||
- (NSInteger) numberOfTickMarks
|
||||
{
|
||||
return [_cell numberOfTickMarks];
|
||||
}
|
||||
|
||||
- (NSRect) rectOfTickMarkAtIndex: (int)index
|
||||
- (NSRect) rectOfTickMarkAtIndex: (NSInteger)index
|
||||
{
|
||||
return [_cell rectOfTickMarkAtIndex: index];
|
||||
}
|
||||
|
@ -385,7 +385,7 @@ static Class cellClass;
|
|||
[_cell setAllowsTickMarkValuesOnly: flag];
|
||||
}
|
||||
|
||||
- (void) setNumberOfTickMarks: (int)numberOfTickMarks
|
||||
- (void) setNumberOfTickMarks: (NSInteger)numberOfTickMarks
|
||||
{
|
||||
[_cell setNumberOfTickMarks: numberOfTickMarks];
|
||||
}
|
||||
|
@ -400,7 +400,7 @@ static Class cellClass;
|
|||
return [_cell tickMarkPosition];
|
||||
}
|
||||
|
||||
- (double) tickMarkValueAtIndex: (int)index
|
||||
- (double) tickMarkValueAtIndex: (NSInteger)index
|
||||
{
|
||||
return [_cell tickMarkValueAtIndex: index];
|
||||
}
|
||||
|
|
|
@ -699,9 +699,9 @@ float _floatValueForMousePoint (NSPoint point, NSRect knobRect,
|
|||
return f;
|
||||
}
|
||||
|
||||
- (int) indexOfTickMarkAtPoint: (NSPoint)point
|
||||
- (NSInteger) indexOfTickMarkAtPoint: (NSPoint)point
|
||||
{
|
||||
int i;
|
||||
NSInteger i;
|
||||
|
||||
for (i = 0; i < _numberOfTickMarks; i++)
|
||||
{
|
||||
|
@ -714,12 +714,12 @@ float _floatValueForMousePoint (NSPoint point, NSRect knobRect,
|
|||
return NSNotFound;
|
||||
}
|
||||
|
||||
- (int) numberOfTickMarks
|
||||
- (NSInteger) numberOfTickMarks
|
||||
{
|
||||
return _numberOfTickMarks;
|
||||
}
|
||||
|
||||
- (NSRect) rectOfTickMarkAtIndex: (int)index
|
||||
- (NSRect) rectOfTickMarkAtIndex: (NSInteger)index
|
||||
{
|
||||
NSRect rect = _trackRect;
|
||||
float d;
|
||||
|
@ -754,7 +754,7 @@ float _floatValueForMousePoint (NSPoint point, NSRect knobRect,
|
|||
_allowsTickMarkValuesOnly = flag;
|
||||
}
|
||||
|
||||
- (void) setNumberOfTickMarks: (int)numberOfTickMarks
|
||||
- (void) setNumberOfTickMarks: (NSInteger)numberOfTickMarks
|
||||
{
|
||||
_numberOfTickMarks = numberOfTickMarks;
|
||||
if ((_control_view != nil) &&
|
||||
|
@ -779,7 +779,7 @@ float _floatValueForMousePoint (NSPoint point, NSRect knobRect,
|
|||
return _tickMarkPosition;
|
||||
}
|
||||
|
||||
- (double) tickMarkValueAtIndex: (int)index
|
||||
- (double) tickMarkValueAtIndex: (NSInteger)index
|
||||
{
|
||||
if ((index < 0) || (index >= _numberOfTickMarks))
|
||||
{
|
||||
|
|
|
@ -101,7 +101,7 @@
|
|||
}
|
||||
|
||||
- (void) insertTabViewItem: (NSTabViewItem*)tabViewItem
|
||||
atIndex: (int)index
|
||||
atIndex: (NSInteger)index
|
||||
{
|
||||
[tabViewItem _setTabView: self];
|
||||
[_items insertObject: tabViewItem atIndex: index];
|
||||
|
@ -154,15 +154,15 @@
|
|||
[self setNeedsDisplay: YES];
|
||||
}
|
||||
|
||||
- (int) indexOfTabViewItem: (NSTabViewItem*)tabViewItem
|
||||
- (NSInteger) indexOfTabViewItem: (NSTabViewItem*)tabViewItem
|
||||
{
|
||||
return [_items indexOfObject: tabViewItem];
|
||||
}
|
||||
|
||||
- (int) indexOfTabViewItemWithIdentifier: (id)identifier
|
||||
- (NSInteger) indexOfTabViewItemWithIdentifier: (id)identifier
|
||||
{
|
||||
unsigned howMany = [_items count];
|
||||
unsigned i;
|
||||
NSUInteger howMany = [_items count];
|
||||
NSUInteger i;
|
||||
|
||||
for (i = 0; i < howMany; i++)
|
||||
{
|
||||
|
@ -175,12 +175,12 @@
|
|||
return NSNotFound;
|
||||
}
|
||||
|
||||
- (int) numberOfTabViewItems
|
||||
- (NSInteger) numberOfTabViewItems
|
||||
{
|
||||
return [_items count];
|
||||
}
|
||||
|
||||
- (NSTabViewItem*) tabViewItemAtIndex: (int)index
|
||||
- (NSTabViewItem*) tabViewItemAtIndex: (NSInteger)index
|
||||
{
|
||||
return [_items objectAtIndex: index];
|
||||
}
|
||||
|
@ -280,7 +280,7 @@
|
|||
}
|
||||
}
|
||||
|
||||
- (void) selectTabViewItemAtIndex: (int)index
|
||||
- (void) selectTabViewItemAtIndex: (NSInteger)index
|
||||
{
|
||||
if (index < 0 || index >= [_items count])
|
||||
[self selectTabViewItem: nil];
|
||||
|
@ -290,14 +290,14 @@
|
|||
|
||||
- (void) selectTabViewItemWithIdentifier: (id)identifier
|
||||
{
|
||||
int index = [self indexOfTabViewItemWithIdentifier: identifier];
|
||||
NSInteger index = [self indexOfTabViewItemWithIdentifier: identifier];
|
||||
|
||||
[self selectTabViewItemAtIndex: index];
|
||||
}
|
||||
|
||||
- (void) takeSelectedTabViewItemFromSender: (id)sender
|
||||
{
|
||||
int index = -1;
|
||||
NSInteger index = -1;
|
||||
|
||||
if ([sender respondsToSelector: @selector(indexOfSelectedItem)] == YES)
|
||||
{
|
||||
|
@ -305,9 +305,9 @@
|
|||
}
|
||||
else if ([sender isKindOfClass: [NSMatrix class]] == YES)
|
||||
{
|
||||
int cols = [sender numberOfColumns];
|
||||
int row = [sender selectedRow];
|
||||
int col = [sender selectedColumn];
|
||||
NSInteger cols = [sender numberOfColumns];
|
||||
NSInteger row = [sender selectedRow];
|
||||
NSInteger col = [sender selectedColumn];
|
||||
|
||||
if (row >= 0 && col >= 0)
|
||||
{
|
||||
|
@ -464,8 +464,8 @@
|
|||
*/
|
||||
- (NSTabViewItem*) tabViewItemAtPoint: (NSPoint)point
|
||||
{
|
||||
int howMany = [_items count];
|
||||
int i;
|
||||
NSInteger howMany = [_items count];
|
||||
NSInteger i;
|
||||
|
||||
for (i = 0; i < howMany; i++)
|
||||
{
|
||||
|
|
|
@ -447,7 +447,7 @@ static void computeNewSelection
|
|||
}
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int last = [_selectedRows lastIndex];
|
||||
NSUInteger last = [_selectedRows lastIndex];
|
||||
|
||||
if (last == NSNotFound)
|
||||
{
|
||||
|
@ -505,7 +505,7 @@ static void computeNewSelection
|
|||
}
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -556,7 +556,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -604,7 +604,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int last = [_selectedRows lastIndex];
|
||||
NSUInteger last = [_selectedRows lastIndex];
|
||||
|
||||
if (last == NSNotFound)
|
||||
{
|
||||
|
@ -707,7 +707,7 @@ static void computeNewSelection
|
|||
}
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int last = [_selectedRows lastIndex];
|
||||
NSUInteger last = [_selectedRows lastIndex];
|
||||
|
||||
if (last == NSNotFound)
|
||||
{
|
||||
|
@ -757,7 +757,7 @@ static void computeNewSelection
|
|||
}
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -797,7 +797,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -836,7 +836,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int last = [_selectedRows lastIndex];
|
||||
NSUInteger last = [_selectedRows lastIndex];
|
||||
|
||||
if (last == NSNotFound)
|
||||
{
|
||||
|
@ -994,7 +994,7 @@ static void computeNewSelection
|
|||
}
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int last = [_selectedRows lastIndex];
|
||||
NSUInteger last = [_selectedRows lastIndex];
|
||||
|
||||
if (last == NSNotFound)
|
||||
{
|
||||
|
@ -1045,7 +1045,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1085,7 +1085,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1124,7 +1124,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int last = [_selectedRows lastIndex];
|
||||
NSUInteger last = [_selectedRows lastIndex];
|
||||
|
||||
if (last == NSNotFound)
|
||||
{
|
||||
|
@ -1193,7 +1193,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int last = [_selectedRows lastIndex];
|
||||
NSUInteger last = [_selectedRows lastIndex];
|
||||
|
||||
if (last == NSNotFound)
|
||||
{
|
||||
|
@ -1251,7 +1251,7 @@ static void computeNewSelection
|
|||
}
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1299,7 +1299,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1348,7 +1348,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int last = [_selectedRows lastIndex];
|
||||
NSUInteger last = [_selectedRows lastIndex];
|
||||
|
||||
if (last == NSNotFound)
|
||||
{
|
||||
|
@ -1390,7 +1390,7 @@ static void computeNewSelection
|
|||
}
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1414,7 +1414,7 @@ static void computeNewSelection
|
|||
}
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1453,7 +1453,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1509,7 +1509,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1584,7 +1584,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1634,7 +1634,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1678,7 +1678,7 @@ static void computeNewSelection
|
|||
}
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1704,7 +1704,7 @@ static void computeNewSelection
|
|||
}
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1745,7 +1745,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1803,7 +1803,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1879,7 +1879,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -1930,7 +1930,7 @@ static void computeNewSelection
|
|||
|
||||
if (*_selectedRow == -1)
|
||||
{
|
||||
unsigned int first = [_selectedRows firstIndex];
|
||||
NSUInteger first = [_selectedRows firstIndex];
|
||||
|
||||
if (first == NSNotFound)
|
||||
{
|
||||
|
@ -2705,7 +2705,7 @@ byExtendingSelection: (BOOL)flag
|
|||
{
|
||||
BOOL empty = ([indexes firstIndex] == NSNotFound);
|
||||
BOOL changed = NO;
|
||||
unsigned int col;
|
||||
NSUInteger col;
|
||||
|
||||
if (!_selectingColumns)
|
||||
{
|
||||
|
@ -2788,7 +2788,7 @@ byExtendingSelection: (BOOL)flag
|
|||
{
|
||||
BOOL empty = ([indexes firstIndex] == NSNotFound);
|
||||
BOOL changed = NO;
|
||||
unsigned int row;
|
||||
NSUInteger row;
|
||||
|
||||
if (_selectingColumns)
|
||||
{
|
||||
|
@ -2894,8 +2894,8 @@ byExtendingSelection: (BOOL)flag
|
|||
|
||||
if (_selectedColumn == columnIndex)
|
||||
{
|
||||
unsigned int less = [_selectedColumns indexLessThanIndex: columnIndex];
|
||||
unsigned int greater = [_selectedColumns indexGreaterThanIndex: columnIndex];
|
||||
NSUInteger less = [_selectedColumns indexLessThanIndex: columnIndex];
|
||||
NSUInteger greater = [_selectedColumns indexGreaterThanIndex: columnIndex];
|
||||
|
||||
if (less == NSNotFound)
|
||||
{
|
||||
|
@ -2951,8 +2951,8 @@ byExtendingSelection: (BOOL)flag
|
|||
|
||||
if (_selectedRow == rowIndex)
|
||||
{
|
||||
unsigned int less = [_selectedRows indexLessThanIndex: rowIndex];
|
||||
unsigned int greater = [_selectedRows indexGreaterThanIndex: rowIndex];
|
||||
NSUInteger less = [_selectedRows indexLessThanIndex: rowIndex];
|
||||
NSUInteger greater = [_selectedRows indexGreaterThanIndex: rowIndex];
|
||||
|
||||
if (less == NSNotFound)
|
||||
{
|
||||
|
@ -4814,7 +4814,7 @@ This method is deprecated, use -columnIndexesInRect:. */
|
|||
selected rows below the new end of the table */
|
||||
if (!_selectingColumns)
|
||||
{
|
||||
int row = [_selectedRows lastIndex];
|
||||
NSUInteger row = [_selectedRows lastIndex];
|
||||
|
||||
if (row == NSNotFound)
|
||||
{
|
||||
|
@ -4822,7 +4822,7 @@ This method is deprecated, use -columnIndexesInRect:. */
|
|||
{
|
||||
/* We shouldn't allow empty selection - try
|
||||
selecting the last row */
|
||||
int lastRow = _numberOfRows - 1;
|
||||
NSInteger lastRow = _numberOfRows - 1;
|
||||
|
||||
if (lastRow > -1)
|
||||
{
|
||||
|
@ -5278,7 +5278,7 @@ This method is deprecated, use -columnIndexesInRect:. */
|
|||
|
||||
- (void) setHighlightedTableColumn: (NSTableColumn *)aTableColumn
|
||||
{
|
||||
int tableColumnIndex;
|
||||
NSUInteger tableColumnIndex;
|
||||
|
||||
tableColumnIndex = [_tableColumns indexOfObject: aTableColumn];
|
||||
|
||||
|
@ -6650,7 +6650,7 @@ For a more detailed explanation, -setSortDescriptors:. */
|
|||
- (NSArray *) _indexSetToArray: (NSIndexSet*)indexSet
|
||||
{
|
||||
NSMutableArray *array = [NSMutableArray array];
|
||||
unsigned int index = [indexSet firstIndex];
|
||||
NSUInteger index = [indexSet firstIndex];
|
||||
|
||||
while (index != NSNotFound)
|
||||
{
|
||||
|
@ -6715,7 +6715,7 @@ For a more detailed explanation, -setSortDescriptors:. */
|
|||
- (void) _unselectAllRows
|
||||
{
|
||||
/* Compute rect to redraw to clear the old row selection */
|
||||
unsigned int row = [_selectedRows firstIndex];
|
||||
NSUInteger row = [_selectedRows firstIndex];
|
||||
|
||||
while (row != NSNotFound)
|
||||
{
|
||||
|
@ -6734,7 +6734,7 @@ For a more detailed explanation, -setSortDescriptors:. */
|
|||
- (void) _unselectAllColumns
|
||||
{
|
||||
/* Compute rect to redraw to clear the old column selection */
|
||||
unsigned int column = [_selectedColumns firstIndex];
|
||||
NSUInteger column = [_selectedColumns firstIndex];
|
||||
|
||||
while (column != NSNotFound)
|
||||
{
|
||||
|
|
|
@ -261,7 +261,7 @@ NSString *GSMovableToolbarItemPboardType = @"GSMovableToolbarItemPboardType";
|
|||
NSImage *image = [[NSImage alloc] initWithSize: viewSize];
|
||||
NSCell *cell = [self cell];
|
||||
NSPasteboard *pboard;
|
||||
int index = NSNotFound;
|
||||
NSInteger index = NSNotFound;
|
||||
|
||||
// Prepare the drag
|
||||
|
||||
|
@ -753,7 +753,7 @@ NSString *GSMovableToolbarItemPboardType = @"GSMovableToolbarItemPboardType";
|
|||
NSSize viewSize = [self frame].size;
|
||||
NSImage *image = [[NSImage alloc] initWithSize: viewSize];
|
||||
NSPasteboard *pboard;
|
||||
int index = NSNotFound;
|
||||
NSInteger index = NSNotFound;
|
||||
|
||||
// Prepare the drag
|
||||
|
||||
|
|
|
@ -777,7 +777,7 @@ GSSetDragTypes(NSView* obj, NSArray *types)
|
|||
positioned: (NSWindowOrderingMode)place
|
||||
relativeTo: (NSView*)otherView
|
||||
{
|
||||
unsigned index;
|
||||
NSUInteger index;
|
||||
|
||||
if (aView == nil)
|
||||
{
|
||||
|
|
|
@ -278,9 +278,9 @@ has blocked and waited for events.
|
|||
- (void) _lossOfKeyOrMainWindow
|
||||
{
|
||||
NSArray *windowList = GSOrderedWindows();
|
||||
unsigned pos = [windowList indexOfObjectIdenticalTo: self];
|
||||
unsigned c = [windowList count];
|
||||
unsigned i;
|
||||
NSUInteger pos = [windowList indexOfObjectIdenticalTo: self];
|
||||
NSUInteger c = [windowList count];
|
||||
NSUInteger i;
|
||||
|
||||
// Don't bother when application is closing.
|
||||
if ([NSApp isRunning] == NO)
|
||||
|
|
Loading…
Reference in a new issue