kos*_*kos 2 xamarin.ios monotouch.dialog
我目前正在使用 Monotouch.Dialog 中概述的高级编辑 tableview,它允许用户删除和编辑 table 元素的标签。有没有办法丰富 tableview 以实现类似于屏幕截图的内容,即更改排序?

您需要将这两个方法添加到您的 DialogViewController.Source
public override bool CanMoveRow (UITableView tableView, NSIndexPath indexPath)
{
return true;
}
public override void MoveRow (UITableView tableView, NSIndexPath sourceIndexPath, NSIndexPath destinationIndexPath)
{
tableView.MoveRow(sourceIndexPath,destinationIndexPath);
}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
756 次 |
| 最近记录: |