Access iOS 7 hidden UITableViewCellScrollView?

后端 未结 2 739
庸人自扰
庸人自扰 2021-02-06 13:40

Apple change the UITableViewCell hierarchy in iOS 7

Using iOS 6.1 SDK


   | 
   |           


        
2条回答
  •  被撕碎了的回忆
    2021-02-06 14:35

    The only way to access the new CellScrollView is by accessing the cell superview after it was created.

    I added the following cellForRowAtIndexPath:

    cell = [[UICustomTableViewCell alloc] init];
    UIView *cellScrollView = cell.myLabel.superview;
    [cellScrollView.layer setMasksToBounds: NO];
    

    I think Apple should give us a way to access this new ScrollView without hacking.

提交回复
热议问题