iOS内存警告处理
- (void)didReceiveMemoryWarning//内存警告
{
[super didReceiveMemoryWarning];
// Dispose of any resources that can be recreated.
NSLog(@"内存快爆了");
//判断是否加载过 或者是否正在屏幕上显示
if([self isViewLoaded]==YES &&self.view.window==nil){
//将跟视图销毁
self.view=nil;
}
}
posted on 2015-07-24 10:15 yucaijiang 阅读(202) 评论(0) 编辑 收藏 举报