【UIKit-110-4】#import <UIKit/UITableView.h>编辑模式

来源:互联网 发布:axure for mac 编辑:程序博客网 时间:2024/05/17 08:24

【编辑状态】

@interface UITableView :UIScrollView <NSCoding>


@property (nonatomic,getter=isEditing) BOOL editing;                   // default is NO. 

- (void)setEditing:(BOOL)editing animated:(BOOL)animated;

结合VC中的edit方法使用,

-(void)setEditing:(BOOL)editing animated:(BOOL)animated{    if (editing) {        [theTableView setEditing:!theTableView.editing animated:YES];    }else{        [theTableView setEditing:!theTableView.editing animated:YES];    }}



@property (nonatomic)BOOL allowsSelection// default is YES. 支持选中

@property (nonatomic)BOOL allowsSelectionDuringEditing;                // default is NO. 编辑时可以选中

@property (nonatomic)BOOL allowsMultipleSelectio;        // default is NO. 支持多选

@property (nonatomic)BOOL allowsMultipleSelectionDuringEditing;  // default is NO. 编辑时支持多选




0 0