TestsTested | ✗ |
LangLanguage | Obj-CObjective C |
License | MIT |
ReleasedLast Release | Dec 2015 |
Maintained by Grigory Lutkov.
iOS pull to refresh for UIScrollView, UITableView and UICollectionView.
platform :ios, '6.0'
pod 'LGRefreshView', '~> 1.0.0'
github "Friend-LGA/LGRefreshView" ~> 1.0.0
In the source files where you need to use the library, import the header file:
#import "LGRefreshView.h"
You have several methods for initialization:
- (instancetype)initWithScrollView:(UIScrollView *)scrollView; // also you can pass UITableView and UICollectionView, becose its subclasses of UIScrollView
More init methods you can find in LGRefreshView.h
To handle actions you can use initialization methods with blocks or delegate, or implement it after initialization.
@property (assign, nonatomic) id<LGRefreshViewDelegate> delegate;
- (void)refreshViewRefreshing:(LGRefreshView *)refreshView;
@property (strong, nonatomic) void (^refreshHandler)(LGRefreshView *refreshView);
Here is also some notifications, that you can add to NSNotificationsCenter:
kLGRefreshViewBeginRefreshingNotification;
kLGRefreshViewEndRefreshingNotification;
For more details try Xcode Demo project and see LGRefreshView.h
LGRefreshView is released under the MIT license. See LICENSE for details.