Refactor: Got rid of all Analyzer warning except for "View is clipping its contents"

This commit is contained in:
Ali Rizvi 2011-09-02 17:51:07 -07:00 committed by Gennadiy Potapov
parent 2ecdb49a27
commit 198a2af5eb
3 changed files with 8 additions and 10 deletions

View file

@ -340,8 +340,9 @@
case NSHomeFunctionKey:
if ( [clippingStore jcListCount] > 0 ) {
stackPosition = 0;
[bezel setCharString:[NSString stringWithFormat:@"%d of %d", stackPosition + 1, [clippingStore jcListCount]]];
//[bezel setCharString:[NSString stringWithFormat:@"%d", stackPosition + 1]];
[bezel setCharString:[NSString stringWithFormat:@"%d of %d",
1, [clippingStore jcListCount]]];
[bezel setText:[clippingStore clippingContentsAtPosition:stackPosition]];
}
break;

View file

@ -489,14 +489,12 @@ static OSStatus SendEventToSystemEventsWithParameters(
AppleEvent target;
AppleEvent event;
AppleEvent localReply;
AEDescList results;
assert( (reply == NULL) || (reply->descriptorType == typeNull) );
target = kAENull;
event = kAENull;
localReply = kAENull;
results = kAENull;
// Create Apple event.

View file

@ -39,7 +39,7 @@ Constructor:
-(id) init
{
if( self = [super init] )
if( [super init] )
{
tabView = nil;
itemsList = [[NSMutableDictionary alloc] init];
@ -294,11 +294,10 @@ This is simply a list of all tab view items in order.
-(NSArray*) toolbarDefaultItemIdentifiers: (NSToolbar *) toolbar
{
int itemCount = [tabView numberOfTabViewItems],
x;
NSTabViewItem* theItem = [tabView tabViewItemAtIndex:0];
//NSMutableArray* defaultItems = [NSMutableArray arrayWithObjects: [theItem identifier], NSToolbarSeparatorItemIdentifier, nil];
NSMutableArray* defaultItems = [NSMutableArray array];
int itemCount = [tabView numberOfTabViewItems];
int x;
NSTabViewItem* theItem;
NSMutableArray* defaultItems = [NSMutableArray array];
for( x = 0; x < itemCount; x++ )
{