我在模拟器上成功运行了一个 iPhone 应用程序,但是当我尝试在设备上运行它时,它卡在了一个特定的视图上,我有一个带有按钮的自定义单元格的表格视图。当我按下按钮超过四五次后,应用程序正常工作,我也检查了它的自动调整大小,我不知道为什么它在设备上不能正常工作,请帮忙?
- (IBAction)didSelectCelebrityNameWithButton:(UIButton *)sender
{
CustomVC *customVC;
if(isFiltered)
{
NSLog(@"Celebrity Name : %i", sender.tag-1000);
customVC = [filteredListResults objectAtIndex:sender.tag-1000];
}
else
{
customVC = [listResults objectAtIndex:sender.tag-1000];
}
if (customVC != nil)
{
if ([[NSUserDefaults standardUserDefaults] objectForKey:UD_FILTER_CELEBRITY_NAME])
{
[[NSUserDefaults standardUserDefaults] removeObjectForKey:UD_FILTER_CELEBRITY_NAME];
}
[[NSUserDefaults standardUserDefaults] setObject:customVC.celebrity_name forKey:UD_FILTER_CELEBRITY_NAME];
[[NSUserDefaults standardUserDefaults] synchronize];
RefinedCurrentSearchVC *refinedCurrentSearchVC = [[RefinedCurrentSearchVC alloc] initWithNibName:@"RefinedCurrentSearchVC_iPhone" bundle:nil];
refinedCurrentSearchVC.isCelebrityFilter = YES;
[self.navigationController pushViewController:refinedCurrentSearchVC animated:YES];
}
}
我正在运行 xcode 4.6.2 并更改了其部署目标 4.3 但仍然存在问题,