Pull-to-Refresh.Rentals-IOS 1.0

Pull-to-Refresh.Rentals-IOS 1.0

测试已测试
语言语言 Obj-CObjective C
许可协议 MIT
发布最后发布2016年7月

Serhii Butenko 维护。



本项目旨在提供一个简单且可定制的下拉刷新实现。

Yalantis

查看这个 [Dribbble 上的项目] (https://dribbble.com/shots/1650317-Pull-to-Refresh-Rentals)
查看这个 [Behance 上的项目] (https://www.behance.net/gallery/20411445/Mobile-Animations-Interactions)

alt text

#使用方法

对于工作的实现,请查看样本项目 - sample

  1. 将 YALSunnyRefreshControll 文件夹添加到项目中。
  2. 实现头文件并设置 YALSunnyRefreshControl 为属性。
  3. 初始化并将 YALSunnyRefreshControl 与您的 UITableView 或 UICollectionView 关联。
  4. 将 Sample Project 中 Images.xcassets 文件夹中的图像添加到项目中。
#import "YALSunnyRefreshControl.h"

@property (nonatomic,strong) YALSunnyRefreshControl *sunnyRefreshControl;

- (void)viewDidLoad {
    [super viewDidLoad];
    [self setupRefreshControl];
}

-(void)setupRefreshControl{
    
    self.sunnyRefreshControl = [YALSunnyRefreshControl attachToScrollView:self.tableView
                                                                  target:self
                                                           refreshAction:@selector(sunnyControlDidStartAnimation)];
    
}

-(void)sunnyControlDidStartAnimation{
    
    // start loading something
}

-(IBAction)endAnimationHandle{
    
    [self.sunnyRefreshControl endRefreshing];
}

#定制

要自定义可绘制的对象,您可以更改以下内容:

  • sun.png - 日图像
  • sky.png - 背景图像
  • buildings.png - 前景图像

#兼容性

  • IOS 7,8

变更日志

版本:1.0

  • 初始构建

许可协议

Copyright 2015, Yalantis

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   https://apache.ac.cn/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.