targetcloud / Tgrefreshoc
Licence: mit
弹簧、橡皮筋下拉刷新控件,类似QQ下拉刷新效果,同时支持其他样式
Stars: ✭ 149
Projects that are alternatives of or similar to Tgrefreshoc
React Native Mjrefresh
基于ios MJRefresh https://github.com/CoderMJLee/MJRefresh 开发的插件,可提供自定义的弹性刷新
Stars: ✭ 140 (-6.04%)
Mutual labels: refresh
Elastic Docker
Example setups for Elasticsearch, Kibana, Logstash, and Beats with docker-compose
Stars: ✭ 118 (-20.81%)
Mutual labels: elastic
Qqlight Websocket
QQLight机器人WebSocket-RPC插件,让你能够使用任何语言编写QQ机器人程序
Stars: ✭ 118 (-20.81%)
Mutual labels: qq
Elastic Stack
Aprenda Elasticsearch, Logstash, Kibana e Beats do jeito mais fácil ⭐️
Stars: ✭ 135 (-9.4%)
Mutual labels: elastic
Elastic
Elastic Stack (6.2.4) 을 활용한 Dashboard 만들기 Project
Stars: ✭ 121 (-18.79%)
Mutual labels: elastic
Electronic Qq
[FREEZED]the electionic-QQ based on smart-qq & electronic-wechat written in Nodejs
Stars: ✭ 144 (-3.36%)
Mutual labels: qq
View Load Retry
这个加载框架有点不一样,针对View进行加载,加载页面还保持了原View的属性,侧重点在灵活,哪里需要加载哪里,加载状态页面完全自定义,无任何限制,针对加载结果可以按需配置对应页面,LeakCanary检测无内存泄漏
Stars: ✭ 119 (-20.13%)
Mutual labels: refresh
Sigmaui
SIGMA UI is a free open-source application based on the Elastic stack and Sigma Converter (sigmac)
Stars: ✭ 123 (-17.45%)
Mutual labels: elastic
Quicklogger
Library for logging on files, console, memory, email, rest, eventlog, syslog, slack, telegram, redis, logstash, elasticsearch, influxdb, graylog, Sentry, Twilio, ide debug messages and throw events for Delphi/Firemonkey/freepascal/.NET (Windows/Linux/OSX/IOS/Android).
Stars: ✭ 137 (-8.05%)
Mutual labels: elastic
Mojo Webqq
【重要通知:WebQQ将在2019年1月1日停止服务,此项目目前已停止维护,感谢大家四年来的一路陪伴】使用Perl语言(不会没关系)编写的smartqq/webqq客户端框架(非GUI),可通过插件提供基于HTTP协议的api接口供其他语言或系统调用
Stars: ✭ 1,755 (+1077.85%)
Mutual labels: qq
Coolq Http Api
为 酷Q 提供通过 HTTP 或 WebSocket 接收事件和调用 API 的能力
Stars: ✭ 1,787 (+1099.33%)
Mutual labels: qq
TGRefreshOC
弹簧、橡皮筋下拉刷新控件,类似QQ下拉刷新控件,但比QQ 更强,同时支持其他样式,目前总共2种样式,后续不断添加中...
Swift Version
https://github.com/targetcloud/TGRefreshSwift
Recently Updated
- 0.1.3 增加ignoreScrollViewContentInsetTop属性
- 0.1.2 增加回显信息的渐显与渐隐时间属性设置
- 0.1.1 优化并增强容错设计处理
- 0.1.0 去掉了计时器,提高了性能,同时增加了容错性设计处理
Features
- [x] 支持链式编程配置,程序员的最爱
- [x] 支持两种刷新结果提示
- [x] 支持QQ和Normal两种下拉刷新样式
- [x] 支持contentInset
- [x] 支持Cocoapods
- [x] 支持MJRefresh到TGRefresh风格切换,只需要把mj_header改为tg_header,改动2个字母即可
- [x] 支持4种配置方式,普通配置、一句话配置、高级配置、最优配置,推荐使用最优配置
- [x] 支持刷新结果回显配置
- [x] 超轻量级、使用超灵活、功能超强大
- [x] 用例丰富,快速上手
Usage
首先写上这一句(必须的)
#import <TGRefresh.h>
如果需要,在你的控制器中加上一句
self.automaticallyAdjustsScrollViewInsets=NO;
QQ效果
self.tableview.tg_header = [TGRefreshOC refreshWithTarget:self action:@selector(doRefreshSenior) config:nil];
普通效果
self.tableview.tg_header = [TGRefreshOC refreshWithTarget:self action:@selector(doRefreshSenior) config:^(TGRefreshOC *refresh) {
refresh.tg_kind(RefreshKindNormal);
}];
更多配置,使用链式编程配置
self.tableview.tg_header = [TGRefreshOC refreshWithTarget:self action:@selector(doRefreshSenior) config:^(TGRefreshOC *refresh) {
refresh.tg_refreshResultBgColor([[UIColor orangeColor] colorWithAlphaComponent:0.8])
.tg_bgColor([UIColor colorWithWhite:0.8 alpha:1])
.tg_refreshResultTextColor([UIColor whiteColor]);
}];
开始刷新
[self.tableview.tg_header beginRefreshing];
(网络请求等情况得到数据后)结束刷新
[self.tableview.tg_header endRefreshing];
结束刷新时的回显
self.tableview.tg_header.refreshResultStr = @"成功刷新数据来自回显信息”;
[self.tableview.tg_header endRefreshing];
可以配置的属性
/** 类型,默认为QQ弹簧 皮筋效果 */
@property(nonatomic,assign) TGRefreshKind kind;
/** 背景色(在有contentInset时为scrollview等背景色) */
@property(nonatomic,strong) UIColor * bgColor;
/** 主题色(刷新文字颜色、ActivityIndicator颜色、橡皮筯颜色) */
@property(nonatomic,strong) UIColor * tinColor;
/** 垂直对齐,默认顶部 */
@property(nonatomic,assign) TGRefreshAlignment verticalAlignment;
/** 刷新成功时的提示文字 */
@property(nonatomic,copy) NSString * refreshSuccessStr;
/** 准备刷新时的提示文字 */
@property(nonatomic,copy) NSString * refreshNormalStr;
/** 即将刷新时的提示文字 */
@property(nonatomic,copy) NSString * refreshPullingStr;
/** 正在刷新时的提示文字 */
@property(nonatomic,copy) NSString * refreshingStr;
/** 更新结果的回显文字 */
@property(nonatomic,copy) NSString * refreshResultStr;
/** 更新结果的回显背景色 */
@property(nonatomic,strong) UIColor * refreshResultBgColor;
/** 更新结果的回显文字颜色 */
@property(nonatomic,strong) UIColor * refreshResultTextColor;
/** 更新结果的回显高度 */
@property(nonatomic,assign) CGFloat refreshResultHeight;
/** 自动改变透明度,默认已做优化 */
@property(nonatomic,assign) BOOL automaticallyChangeAlpha;
/** 回显时的渐显时间 0.1 ~ 2秒 默认0.5 */
@property(nonatomic,assign) CGFloat fadeinTime;
/** 回显时的渐隐时间 0.1 ~ 5秒 默认1.5 */
@property(nonatomic,assign) CGFloat fadeoutTime;
/** 忽略初始的InsetTop */
@property(nonatomic,assign) BOOL ignoreScrollViewContentInsetTop;
使用链式编程配置时,请在所有属性前加tg_前缀即可
更多使用配置组合效果请下载本项目或fork本项目查看
Installation
-
下载并拖动TGRefreshOC到你的工程中,只需要拖动包含TGRefresh.h这一文件的目录即可
-
Cocoapods
pod 'TGRefreshOC'
Reference
- http://blog.csdn.net/callzjy
- https://github.com/targetcloud/baisibudejie
- https://github.com/targetcloud/TGImage
运行效果
demo中的弹簧效果
demo中的Normal效果
如果你觉得赞,请Star
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].