royalwang / FantasyView

FantasyView is a horizontal tableview.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

FantasyView

FantasyView is a horizontal tableview.

FantasyView.h:

#import <UIKit/UIKit.h>

@protocol FantasyViewDataSource; @protocol FantasyViewDelegate;

@interface FantasyView : UIView

@property (nonatomic, retain) UITableView *tableView; @property (nonatomic, assign) id dataSource; @property (nonatomic, assign) id delegate; @property (nonatomic, assign) NSInteger currentIndex; @property (nonatomic, assign) BOOL pagingEnabled;

  • (void)reloadData;
  • (void)fantasyViewScrollToIndex:(NSInteger)index animation:(BOOL)animation;
  • (UIView *)getViewInFantasyViewWithIndex:(NSInteger)index;

@end

@protocol FantasyViewDelegate

@optional

  • (void)fantasyView:(FantasyView *)fanView selectIndex:(NSInteger)index;
  • (void)fantasyView:(FantasyView *)fanView scrollToIndex:(NSInteger)index;

@end

@protocol FantasyViewDataSource

@required

  • (CGFloat)fantasyView:(FantasyView *)fanView widthForIndex:(NSInteger)index;
  • (NSInteger)numberOfIndexForFantasyView:(FantasyView *)fanView;
  • (void)fantasyView:(FantasyView *)fanView setContentView:(UIView *)contentView ForIndex:(NSInteger)index;
  • (UIView *)fantasyView:(FantasyView *)fanView targetRect:(CGRect)targetRect ForIndex:(NSInteger)index;

@end

About

FantasyView is a horizontal tableview.