From e647d64d34c666cc10ae36999674d4c6c44eda86 Mon Sep 17 00:00:00 2001 From: Gregory John Casamento Date: Thu, 28 Aug 2003 04:32:41 +0000 Subject: [PATCH] Minor corrections. Reduced log output and added logic to prevent exception. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/apps/gorm/trunk@17561 72102866-910b-0410-8b05-ffd578937521 --- ChangeLog | 10 ++++++++-- GormClassInspector.m | 7 ++++++- GormDocument.m | 8 ++++---- 3 files changed, 18 insertions(+), 7 deletions(-) diff --git a/ChangeLog b/ChangeLog index 1dabaf86..d8a63f8c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,10 @@ -2003-08-23 Gregory John Casamento +2003-08-28 Gregory John Casamento + + * GormDocument.m: Cleanup some of the extra logs. + * GormClassInspector.m: Add logic to prefent index out of bounds + exception. + +2003-08-27 Gregory John Casamento * GormDocument.m: Corrected some memory related issues. * GormCustomClassManager.m: Added to log which informs @@ -6,7 +12,7 @@ * Gorm.m: Cleaned up some comments and updated the version of the application. -2003-08-23 Gregory John Casamento +2003-08-26 Gregory John Casamento * GormDocument.m: Added some debug logs. And in _replaceObjectsWithTemplates: modified the method to use the diff --git a/GormClassInspector.m b/GormClassInspector.m index 15467adc..cd865c7a 100644 --- a/GormClassInspector.m +++ b/GormClassInspector.m @@ -62,7 +62,12 @@ objectValueForTableColumn: (NSTableColumn *)tc row: (int)rowIndex { NSArray *list = [[(Gorm *)NSApp classManager] allOutletsForClassNamed: [inspector _currentClass]]; - return [list objectAtIndex: rowIndex]; + id value = nil; + if([list count] > 0) + { + value = [list objectAtIndex: rowIndex]; + } + return value; } - (void) tableView: (NSTableView *)tv diff --git a/GormDocument.m b/GormDocument.m index 156db7fb..52a82c57 100644 --- a/GormDocument.m +++ b/GormDocument.m @@ -1906,8 +1906,8 @@ static NSImage *classesImage = nil; [[c nameTable] setObject: cc forKey: GSCustomClassMap]; } [classManager setCustomClassMap: cc]; - NSLog(@"cc = %@", cc); - NSLog(@"customClasses = %@", [classManager customClassMap]); + NSDebugLog(@"cc = %@", cc); + NSDebugLog(@"customClasses = %@", [classManager customClassMap]); // convert from old file format... if (isDir == NO) @@ -2655,9 +2655,9 @@ static NSImage *classesImage = nil; [self _replaceObjectsWithTemplates: archiver]; [archiver encodeRootObject: self]; - NSLog(@"nameTable = %@",nameTable); + NSDebugLog(@"nameTable = %@",nameTable); - NSLog(@"customClasses = %@", [classManager customClassMap]); + NSDebugLog(@"customClasses = %@", [classManager customClassMap]); fileExists = [mgr fileExistsAtPath: documentPath isDirectory: &isDir]; if (fileExists)