标签:uitableview uinavigationcontroll
本章主要在上一章的基础上修改,把其改为导航控制器的例子,其他的改变不大
主要代码
#pragma UITableViewDelegate - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { // 修改子页面的信息 NSString* cityName = [[self._dictProvince objectForKey:[self._arrayKeys objectAtIndex:indexPath.section]] objectAtIndex:indexPath.row]; self._cityView.title = cityName; self._cityView.view.backgroundColor = [UIColor colorWithRed:arc4random()%100/100.0f green:arc4random()%100/100.0f blue:arc4random()%100/100.0f alpha:1.0f]; // 导航到下一级页面 [self.navigationController pushViewController:self._cityView animated:YES]; }
标签:uitableview uinavigationcontroll
原文地址:http://blog.csdn.net/arbboter/article/details/41786963