iPhoneのTableViewで各行の右側に矢印を追加したいです。これを行う方法はありますか?
2314 次
2 に答える
3
多くのアプリにあるデフォルトの矢印 (シェブロン) のことですか?
UITableViewCell *myCell = ...; //GET a cell from somewhere.
myCell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
于 2009-02-26T06:28:37.670 に答える
0
私はちょうどそれを解決しました:
-(UITableViewCellAccessoryType)tableView:(UITableView *)tableView
accessoryTypeForRowWithIndexPath:(NSIndexPath *)indexPath
{
return UITableViewCellAccessoryDetailDisclosureButton;
}
-(void)tableView:(UITableView *)tableView
accessoryButtonTappedForRowWithIndexPath:(NSIndexPath *)indexPath
{
//add action here
}
各行の右側に青い矢印が表示されます。
于 2009-02-26T06:28:17.470 に答える