• Stars
    star
    383
  • Rank 111,995 (Top 3 %)
  • Language
    Objective-C
  • License
    Other
  • Created over 12 years ago
  • Updated over 7 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

SlimeRefresh looks like UIRefreshControl in iOS6, SlimeRefresh can also run on iOS4.0 and later , and SlimeRefresh can action on UIScrollView.

SlimeRefresh

A lovely refreshing style looks like UIRefreshControl. It looks like the Slime so I named it SlimeRefresh.

Screenshot:

screenshots screenshots screenshots screenshots

screenshots

screenshots

screenshots

Usage

1,download the source from https://github.com/dbsGen/SlimeRefresh/

  • git : git clone https://github.com/dbsGen/SlimeRefresh.git SlimeRefresh

2,add all under SlimeRefresh/SlimeRefresh to your project.

3,#import "SRRefreshView.h"

4,init SRRefreshView and add it to a UIScrollView.

just like:

    _slimeView = [[SRRefreshView alloc] init];
    _slimeView.delegate = self;
    [_tableView addSubview:_slimeView];

Callback

A protocol and a block, choise one.

- (void)slimeRefreshStartRefresh:(SRRefreshView*)refreshView;

Only one protocol, you have to implement. it will be called when the refreshing will be executed.

and here is the other way:

@property (nonatomic, copy)     SRRefreshBlock  block;

as you see there is a block to receive the refresh event.just like:

__block __unsafe_unretained id this = self;
[refreshView setBlock:^(SRRefreshView* sender) { 
    [this load];    //replace this line to your refreshing code.
}];

Style

  • Refere to the demo.

  • The reflesh arrow image :

    • refreshView.refleshView.image = [UIImage imaggeNamed:@"Yours"];
    • refreshView.refreshView.bounds = CGRectMake(0, 0, 23, 23);
    • I'm sorry, it is not a good name.

Bug

  • When in the animation the view controller dealloc, that will make application creash.
    • Use the last version and remove refreshView from it's super view, when view controller dealloced.
- (void)dealloc { [refreshView removeFromSuperview]; }

Others

Ok, that is all. Enjoy it, and this is my blog:http://zhaorenzhi.cn.

More Repositories

1

GenShelfV3_Android

绅士的书架v3 安卓版
C
18
star
2

GenShelf-iOS

绅士的书架iOS版,新版本 https://github.com/dbsGen/GenShelfV3_iOS
Objective-C
15
star
3

YunSDK

关于一些网络硬盘(快盘,百度云)的objective-c 版本的SDK
Objective-C
10
star
4

GenShelfV3_iOS

绅士的书架v3 iOS版
C
7
star
5

PeerJS-Android

Android port peerjs library (data channel only).
Java
7
star
6

binding

Binding GDScript to native languages(Java,Obj-C).
Objective-C++
6
star
7

MTPaddyButton

A paddy button.
Objective-C
6
star
8

XEP-0055

A implementation of XEP-0055. It is a module for XMPPFramework. just for client.
Objective-C
6
star
9

CacheManager

一个objective-c的缓存工具。 a cache tool for objective-c.
Objective-C
6
star
10

my_godot_modules

My godot modules
C++
5
star
11

LieTester

娱乐用测谎仪
Objective-C
4
star
12

my_gdscript

To: https://github.com/dbsGen/godot
3
star
13

GenShelf_Packages

All shop packages of GenShelf
3
star
14

grender

A light weight 3D render.
C++
2
star
15

MTHessian

使hessianKit返回ASIHTTPRequest. | use ASIHTTP to make the hessianKit controllable.
Objective-C
2
star
16

MTDateFormatter

help you to transform date
Objective-C
2
star
17

GTween

A lightweight tween library for iOS.
Objective-C
2
star
18

OACallBack

能稍微减少回调的代码量 | easier to write the callback.
Objective-C
1
star
19

StringPlaceholderFormat

objective-c中类似java占位符的实现 | you can format the string like in java
Objective-C
1
star
20

genyunsdk

用ruby实现baidu云的SDK
Ruby
1
star
21

myFB

一个分享百度网盘上边图片的web应用.
JavaScript
1
star
22

omarket

open apk market on nebulas
JavaScript
1
star
23

MTMatrixView

简单的矩阵列表 | a simple matrix view.
Objective-C
1
star