46 lines
1.1 KiB
Objective-C
46 lines
1.1 KiB
Objective-C
//
|
|
// UIScrollView+SVInfiniteScrolling.h
|
|
//
|
|
// Created by Sam Vermette on 23.04.12.
|
|
// Copyright (c) 2012 samvermette.com. All rights reserved.
|
|
//
|
|
// https://github.com/samvermette/SVPullToRefresh
|
|
//
|
|
|
|
#import <UIKit/UIKit.h>
|
|
|
|
@class SVInfiniteScrollingView;
|
|
|
|
@interface UIScrollView (SVInfiniteScrolling)
|
|
|
|
- (void)addInfiniteScrollingWithActionHandler:(void (^)(void))actionHandler;
|
|
- (void)triggerInfiniteScrolling;
|
|
|
|
@property (nonatomic, strong, readonly) SVInfiniteScrollingView *infiniteScrollingView;
|
|
@property (nonatomic, assign) BOOL showsInfiniteScrolling;
|
|
|
|
@end
|
|
|
|
|
|
enum {
|
|
SVInfiniteScrollingStateStopped = 0,
|
|
SVInfiniteScrollingStateTriggered,
|
|
SVInfiniteScrollingStateLoading,
|
|
SVInfiniteScrollingStateAll = 10
|
|
};
|
|
|
|
typedef NSUInteger SVInfiniteScrollingState;
|
|
|
|
@interface SVInfiniteScrollingView : UIView
|
|
|
|
@property (nonatomic, readwrite) UIActivityIndicatorViewStyle activityIndicatorViewStyle;
|
|
@property (nonatomic, readonly) SVInfiniteScrollingState state;
|
|
@property (nonatomic, readwrite) BOOL enabled;
|
|
|
|
- (void)setCustomView:(UIView *)view forState:(SVInfiniteScrollingState)state;
|
|
|
|
- (void)startAnimating;
|
|
- (void)stopAnimating;
|
|
|
|
@end
|