0
我的didReceiveMemoryWarning
應該是什麼?我沒有看到任何我可以釋放的東西,但仍然記憶猶新。我爲我的managedObjectContext
設置了一個屬性,對於ivars來說就是這樣。didReceiveMemoryWarning trouble
- (void)viewDidLoad
{
[super viewDidLoad];
UIBarButtonItem *calendar = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"calendar.png"]style:UIBarButtonItemStyleBordered target:self action:@selector(viewCal)];
self.navigationItem.rightBarButtonItem = calendar;
[calendar release];
UIBarButtonItem *settings = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"gears.png"] style:UIBarButtonItemStyleBordered target:self action:@selector(viewSettings)];
self.navigationItem.leftBarButtonItem = settings;
[settings release];
[SHK flushOfflineQueue];
[self clearNullWorkouts];
}
- (void)didReceiveMemoryWarning
{
// Releases the view if it doesn't have a superview.
[super didReceiveMemoryWarning];
// Relinquish ownership any cached data, images, etc that aren't in use.
}