Skip to content

Commit

Permalink
fix the indicatorRadius size
Browse files Browse the repository at this point in the history
  • Loading branch information
xhzengAIB committed Aug 7, 2015
1 parent ee9ede5 commit 4234b25
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions RefreshControl/Views/XHPinterestRefreshView.m
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,12 @@ - (instancetype)initWithFrame:(CGRect)frame {
}

- (void)willStartRefreshing {
[self.activityIndicatorView startAnimating];
[UIView animateWithDuration:0.1 delay:0 options:UIViewAnimationOptionCurveEaseInOut animations:^{
[UIView animateWithDuration:0.2 delay:0 options:UIViewAnimationOptionCurveEaseInOut|UIViewAnimationOptionAllowUserInteraction | UIViewAnimationOptionBeginFromCurrentState animations:^{
self.circularProgressView.alpha = 0.0;
self.activityIndicatorView.alpha = 1.0;
} completion:^(BOOL finished) {
}];
[self.activityIndicatorView startAnimating];
}
- (void)didStartRefreshing {
}
Expand All @@ -45,12 +46,12 @@ - (void)refreing {
}

- (void)willEndRefreshing {
[self.activityIndicatorView stopAnimating];
[UIView animateWithDuration:0.1 delay:0 options:UIViewAnimationOptionCurveEaseInOut animations:^{
[UIView animateWithDuration:0.2 delay:0 options:UIViewAnimationOptionCurveEaseInOut|UIViewAnimationOptionAllowUserInteraction | UIViewAnimationOptionBeginFromCurrentState animations:^{
self.circularProgressView.alpha = 1.0;

self.activityIndicatorView.alpha = 0.0;
} completion:^(BOOL finished) {
}];
[self.activityIndicatorView stopAnimating];
}
- (void)didEndRefresing {
}
Expand All @@ -70,8 +71,8 @@ - (void)setPullDownOffset:(CGFloat)pullDownOffset {
- (XHActivityIndicatorView *)activityIndicatorView {
if (!_activityIndicatorView) {
_activityIndicatorView = [[XHActivityIndicatorView alloc] initWithFrame:CGRectMake(0, 0, 50, 50)];
_activityIndicatorView.hidesWhenStopped = YES;
_activityIndicatorView.color = [UIColor redColor];
_activityIndicatorView.color = [UIColor colorWithRed:228/255.0 green:27 / 255.0 blue:70/255.0 alpha:1.000];
_activityIndicatorView.indicatorRadius = 6;
_activityIndicatorView.center = CGPointMake(CGRectGetMidX(self.bounds), CGRectGetMidY(self.bounds));
}
return _activityIndicatorView;
Expand Down

0 comments on commit 4234b25

Please sign in to comment.