mirror of
https://github.com/kennethreitz-archive/gitx.git
synced 2026-06-05 23:40:18 +00:00
e570c3e50a
We used to use NSObjects, which was really expensive, because for each commit as many as 100 graphlines can be created. By preallocating them and not using NSObjects in general, we gain a massive speedup
28 lines
432 B
Objective-C
28 lines
432 B
Objective-C
//
|
|
// PBGraphCellInfo.m
|
|
// GitX
|
|
//
|
|
// Created by Pieter de Bie on 27-08-08.
|
|
// Copyright 2008 __MyCompanyName__. All rights reserved.
|
|
//
|
|
|
|
#import "PBGraphCellInfo.h"
|
|
|
|
|
|
@implementation PBGraphCellInfo
|
|
@synthesize lines, position, numColumns, sign, nLines;
|
|
- (id)initWithPosition:(int)p andLines:(struct PBGitGraphLine *)l
|
|
{
|
|
position = p;
|
|
lines = l;
|
|
|
|
return self;
|
|
}
|
|
|
|
-(void) finalize
|
|
{
|
|
free(lines);
|
|
[super finalize];
|
|
}
|
|
|
|
@end |