Day12 TableViewCell 辅助功能

accessoryType

typedef NS_ENUM(NSInteger, UITableViewCellAccessoryType) {
    UITableViewCellAccessoryNone,                   // don't show any accessory view
    UITableViewCellAccessoryDisclosureIndicator,    // regular chevron. doesn't track
    UITableViewCellAccessoryDetailDisclosureButton, // info button w/ chevron. tracks
    UITableViewCellAccessoryCheckmark,              // checkmark. doesn't track
    UITableViewCellAccessoryDetailButton NS_ENUM_AVAILABLE_IOS(7_0) // info button. tracks
};

2 accessoryTypeView 可放一些switch

//cell.accessoryView = [[UISwitch alloc]init];
    cell.accessoryView = [UIButton buttonWithType:UIButtonTypeContactAdd];

  

backgroundColor  

   backgroundView //可放一些圆形的底图

selectedBackgroundView

 UIView *iv = [[UIView alloc]init];
    iv.backgroundColor = [UIColor redColor];
    cell.selectedBackgroundView =iv;

  

posted @ 2015-04-11 11:28  菠萝君  阅读(158)  评论(0编辑  收藏  举报