UITableViewCellshowsReorderControlドキュメントから:
For the reordering control to appear, you must not only set this property but implement the UITableViewDataSource method tableView:moveRowAtIndexPath:toIndexPath:. In addition, if the data source implements tableView:canMoveRowAtIndexPath: to return NO, the reordering control does not appear in that designated row.
tableviewControllerに両方があります:
- (BOOL)tableView:(UITableView *)tableView canMoveRowAtIndexPath:(NSIndexPath *)indexPath {
return YES;
}
- (void)tableView:(UITableView *)tableView moveRowAtIndexPath:(NSIndexPath *)fromIndexPath toIndexPath:(NSIndexPath *)toIndexPath {
NSLog(@"move from:%d to:%d", fromIndexPath.row, toIndexPath.row);
//just for test
}
コントロールの並べ替えを含む私のセルのプロパティ:
それでも、並べ替えコントロールが表示されません。何が欠けていますか?