• 0621


    ////这个也有用

    //- (nullable NSArray<UITableViewRowAction *> *)tableView:(UITableView *)tableView editActionsForRowAtIndexPath:(NSIndexPath *)indexPath{

    //    UITableViewRowAction *firstAction = [UITableViewRowAction rowActionWithStyle:UITableViewRowActionStyleDefault title:@"你猜" handler:^(UITableViewRowAction * _Nonnull action, NSIndexPath * _Nonnull indexPath) {

    //        /** 1. 更新数据源:向数组中添加数据. */

    //        [_autoMarry insertObject:@"abcd" atIndex:indexPath.row];

    //        

    //        /** 2. TableView中插入一个cell. */

    //        [tableView insertRowsAtIndexPaths:@[indexPath] withRowAnimation:UITableViewRowAnimationAutomatic];

    //        

    //        NSLog(@"22");

    //        

    //    }];

    //    UITableViewRowAction *secondAction = [UITableViewRowAction rowActionWithStyle:UITableViewRowActionStyleDefault title:@"我不猜" handler:^(UITableViewRowAction * _Nonnull action, NSIndexPath * _Nonnull indexPath) {

    //        

    //        

    //    }];

    //    firstAction.backgroundColor = [UIColor purpleColor];

    //    secondAction.backgroundColor = [UIColor blueColor];

    //    return @[firstAction,secondAction];

    //}

     

     

     

     

     

     

    /*

     //     点击 + 图标的操作.

    //    if (editingStyle == UITableViewCellEditingStyleInsert) { *< 判断编辑状态是插入时.

    //        * 1. 更新数据源:向数组中添加数据. */

    //        [_autoMarry insertObject:@"abcd" atIndex:indexPath.row];

    //

    //        * 2. TableView中插入一个cell. */

    //        [tableView insertRowsAtIndexPaths:@[indexPath] withRowAnimation:UITableViewRowAnimationAutomatic];

    //        editIndex = indexPath;

    //

    //    }

    // */?

     

     

     

     

    /*另外一个控制器

     

     @property(nonatomic,strong)nameViewController *nameController;

     

     self.nameController=[[nameViewController alloc]init];

     

     

     

     did方法中

     self.nameController.delegate=self;

     [self.navigationController pushViewController:self.nameController animated:YES];

     

     

     .m

     

     

     self.name=self.nameField.text;

     

     if ([self.delegate respondsToSelector:@selector(save:)]) {

     [self.delegate save:self.name];

     }

     

     [self.navigationController popViewControllerAnimated:YES];

     

     

     -(void)save:(NSString *)name{

     

     _realNamepff=name;

     刷新值

     

     [_contentMarr  replaceObjectAtIndex:0 withObject:name];

     //      用来刷新指定的行

     [_tbView reloadRowsAtIndexPaths:@[_nameIndexpath] withRowAnimation:UITableViewRowAnimationNone];

     

     

     }

     */

  • 相关阅读:
    C#驱动mysql明明数值不为空却一直说DBNull.Value的诡异情况
    WinForm解决UI假死
    js实现的简单遮罩层
    mongodb C#连接报错 Invalid credentials for database 'admin'
    c#记录代码运行的耗时。
    C# LINQ
    timeScale减速对动画影响的处理方法(转)
    委托
    Unity3D单例类模板类
    Unity协程(Coroutine)管理类——TaskManager工具分享(转)
  • 原文地址:https://www.cnblogs.com/gzz2016/p/5603918.html
Copyright © 2020-2023  润新知