
Simple, Flexible, Customizable



1. Copy CListView folder into your project's XCode files view
2. Include CListView header file to your viewController.
#import "CListView.h"
3. Add delegate to header file of your viewController.
@interface ViewController : UIViewController {
}
4. Init CListView class in your viewController with array and editing mode
Set editingMode YES to enable all gesture functions of your list view. If you are going to use it read only; set editingMode NO.
CListView *cListView = [[CListView alloc] initWithFrame:self.view.frame];
[cListView setItems:[[NSMutableArray alloc] initWithObjects:@"First Item", @"Second Item", @"Third Item", @"Fourth Item", nil]];
[cListView setEditable:TRUE];
cListView.delegate = self;
[self.view addSubview:_clistView];
5. Add delegate methods
- (void)listItemSelected:(CListViewItem *)_clistViewItem {
}
- (void)listItemDeleted:(CListViewItem *)_clistViewItem {
}
- (void)listItemAdded:(CListViewItem *)_clistViewItem {
}
- (void)listItemMarked:(CListViewItem *)_clistViewItem {
}
- (void)listItemUnMarked:(CListViewItem *)_clistViewItem {
}
- (void)listItemMoved:(CListViewItem *)_clistViewItem fromIndex:(NSInteger)_fromIndex toIndex:(NSInteger)_toIndex {
}
- (void)listItemEditingEnded:(CListViewItem *)_clistViewItem {
}
fine for iPhone but needs to be updated with both iPad and iPhone in mind.
Questions & Comments