- (void)tableView:(NSTableView *)aTableView
setObjectValue:(id)anObject
forTableColumn:(NSTableColumn *)aTableColumn
- row:(int)rowIndex
+ row:(NSInteger)rowIndex
{
if(aTableColumn != nil && [[aTableColumn identifier] intValue] == 2)
{
- (id)tableView:(NSTableView *)aTableView
objectValueForTableColumn:(NSTableColumn *)aTableColumn
- row:(int)rowIndex
+ row:(NSInteger)rowIndex
{
NSString *cellEntry = @"__DATA ERROR__";
NSTableView *chapterTable = [notification object];
NSInteger column = [chapterTable editedColumn];
NSInteger row = [chapterTable editedRow];
- int textMovement;
+ NSInteger textMovement;
// Edit the cell in the next row, same column
row++;
- textMovement = [[[notification userInfo] objectForKey:@"NSTextMovement"] intValue];
+ textMovement = [[[notification userInfo] objectForKey:@"NSTextMovement"] integerValue];
if( textMovement == NSReturnTextMovement && row < [chapterTable numberOfRows] )
{
NSArray *info = [NSArray arrayWithObjects:chapterTable,
- (IBAction)applyQueueSettings:(id)sender;
- (void) removeQueueFileItem:(int) queueItemToRemove;
- (void) clearQueueAllItems;
-- (void)moveObjectsInQueueArray:(NSMutableArray *)array fromIndexes:(NSIndexSet *)indexSet toIndex:(unsigned)insertIndex;
+- (void)moveObjectsInQueueArray:(NSMutableArray *)array fromIndexes:(NSIndexSet *)indexSet toIndex:(NSUInteger)insertIndex;
- (void)getQueueStats;
- (void)setQueueEncodingItemsAsPending;
- (IBAction) addToQueue: (id) sender;
- (void) prepareJobForPreview;
- (void) remindUserOfSleepOrShutdown;
-- (void)moveObjectsInPresetsArray:(NSMutableArray *)array fromIndexes:(NSIndexSet *)indexSet toIndex:(unsigned)insertIndex;
+- (void)moveObjectsInPresetsArray:(NSMutableArray *)array fromIndexes:(NSIndexSet *)indexSet toIndex:(NSUInteger)insertIndex;
@end
}
/* this is actually called from the queue controller to modify the queue array and return it back to the queue controller */
-- (void)moveObjectsInQueueArray:(NSMutableArray *)array fromIndexes:(NSIndexSet *)indexSet toIndex:(unsigned)insertIndex
+- (void)moveObjectsInQueueArray:(NSMutableArray *)array fromIndexes:(NSIndexSet *)indexSet toIndex:(NSUInteger)insertIndex
{
- unsigned index = [indexSet lastIndex];
- unsigned aboveInsertIndexCount = 0;
+ NSUInteger index = [indexSet lastIndex];
+ NSUInteger aboveInsertIndexCount = 0;
- while (index != NSNotFound)
- {
- unsigned removeIndex;
-
- if (index >= insertIndex)
- {
- removeIndex = index + aboveInsertIndexCount;
- aboveInsertIndexCount++;
- }
- else
- {
- removeIndex = index;
- insertIndex--;
- }
-
- id object = [[QueueFileArray objectAtIndex:removeIndex] retain];
- [QueueFileArray removeObjectAtIndex:removeIndex];
- [QueueFileArray insertObject:object atIndex:insertIndex];
- [object release];
+
+ NSUInteger removeIndex;
- index = [indexSet indexLessThanIndex:index];
+ if (index >= insertIndex)
+ {
+ removeIndex = index + aboveInsertIndexCount;
+ aboveInsertIndexCount++;
}
+ else
+ {
+ removeIndex = index;
+ insertIndex--;
+ }
+
+ id object = [[QueueFileArray objectAtIndex:removeIndex] retain];
+ [QueueFileArray removeObjectAtIndex:removeIndex];
+ [QueueFileArray insertObject:object atIndex:insertIndex];
+ [object release];
+
+ index = [indexSet indexLessThanIndex:index];
+
/* We save all of the Queue data here
* and it also gets sent back to the queue controller*/
[self saveQueueFileItem];
}
/* We use this to deterimine children of an item */
-- (id)outlineView:(NSOutlineView *)fPresetsOutlineView child:(int)index ofItem:(id)item
+- (id)outlineView:(NSOutlineView *)fPresetsOutlineView child:(NSInteger)index ofItem:(id)item
{
/* we need to return the count of the array in ChildrenArray for this folder */
children = [item objectForKey:@"ChildrenArray"];
}
}
- if ((children == nil) || ([children count] <= index))
+ if ((children == nil) || ( [children count] <= (NSUInteger) index))
{
return nil;
}
return YES;
}
-- (void)moveObjectsInPresetsArray:(NSMutableArray *)array fromIndexes:(NSIndexSet *)indexSet toIndex:(unsigned)insertIndex
+- (void)moveObjectsInPresetsArray:(NSMutableArray *)array fromIndexes:(NSIndexSet *)indexSet toIndex:(NSUInteger)insertIndex
{
- unsigned index = [indexSet lastIndex];
- unsigned aboveInsertIndexCount = 0;
+ NSUInteger index = [indexSet lastIndex];
+ NSUInteger aboveInsertIndexCount = 0;
- while (index != NSNotFound)
+ NSUInteger removeIndex;
+
+ if (index >= insertIndex)
{
- unsigned removeIndex;
-
- if (index >= insertIndex)
- {
- removeIndex = index + aboveInsertIndexCount;
- aboveInsertIndexCount++;
- }
- else
- {
- removeIndex = index;
- insertIndex--;
- }
-
- id object = [[array objectAtIndex:removeIndex] retain];
- [array removeObjectAtIndex:removeIndex];
- [array insertObject:object atIndex:insertIndex];
- [object release];
-
- index = [indexSet indexLessThanIndex:index];
+ removeIndex = index + aboveInsertIndexCount;
+ aboveInsertIndexCount++;
}
+ else
+ {
+ removeIndex = index;
+ insertIndex--;
+ }
+
+ id object = [[array objectAtIndex:removeIndex] retain];
+ [array removeObjectAtIndex:removeIndex];
+ [array insertObject:object atIndex:insertIndex];
+ [object release];
+
+ index = [indexSet indexLessThanIndex:index];
}