All Projects → yangKJ → Kjbannerviewdemo

yangKJ / Kjbannerviewdemo

Licence: mit
轮播图无限自动循环滚动、缩放布局、自带缓存加载读取、支持自定义继承、定制特定样式、动态图和网图混合轮播、支持在Storyboard和Xib中创建并配置其属性、多种滚动方向选择、多种分页控件选择等等

Projects that are alternatives of or similar to Kjbannerviewdemo

Yjbannerview
【抱歉,暂时不提供开源】A very popular and highly customized banner view, 无限循环滚动轮播图BannerView、焦点图, 支持Cocoapods 及 Carthage. 支持完全自定义
Stars: ✭ 506 (+145.63%)
Mutual labels:  cycle, banner
Jxpagecontrol
🚀🚀🚀 自定义pageControl指示器, 支持多种动画, 自定义布局.
Stars: ✭ 246 (+19.42%)
Mutual labels:  cycle, banner
Cycleviewpager2
使用 ViewPager2 实现无限轮播效果,可以用来实现 banner 以及上下滚动文字广告等。Implementing android cycle viewPager with ViewPager2
Stars: ✭ 76 (-63.11%)
Mutual labels:  cycle, banner
Zybannerview
简单易用, 显示内容定制性强的可循环轮播控件. 可以实现类似淘宝商品详情中侧拉进入详情页的功能.
Stars: ✭ 370 (+79.61%)
Mutual labels:  cycle, banner
Tycyclepagerview
a simple and usefull cycle pager view ,and auto scroll banner view(轮播图) ,include pageControl for iOS,support Objective-C and swift
Stars: ✭ 1,548 (+651.46%)
Mutual labels:  cycle, banner
Bannerviewpager
🚀 An awesome banner view for Android,Based on ViewPager2. 这可能是全网最好用的ViewPager轮播图。简单、高效,一行代码实现循环轮播,一屏三页任意变,指示器样式任你挑。
Stars: ✭ 2,603 (+1163.59%)
Mutual labels:  banner
Easytipview
Objective-C alternative for EasyTipView implemented in swift
Stars: ✭ 192 (-6.8%)
Mutual labels:  banner
Sdmusic
Search && Download Music from multi-platform
Stars: ✭ 178 (-13.59%)
Mutual labels:  downloader
Excel Parser Processor
Simply does the tedious, repetitive operations for all rows of excel files step by step and reports after the job is done. It can download files from URL(s) in a column of Excel files. If a new filename is provided at column B it will rename the file before saving. It will even create sub folders if column C is full with a valid folder name.
Stars: ✭ 177 (-14.08%)
Mutual labels:  downloader
Facebook Dl
📼 Very minimal Facebook downloader written in 28 lines of Python code (not including comments and blank spaces)
Stars: ✭ 207 (+0.49%)
Mutual labels:  downloader
Pmalertcontroller
PMAlertController is a great and customizable alert that can substitute UIAlertController
Stars: ✭ 2,397 (+1063.59%)
Mutual labels:  banner
Pyload
The free and open-source Download Manager written in pure Python
Stars: ✭ 2,393 (+1061.65%)
Mutual labels:  downloader
Download Directory.github.io
Web App: Download just a sub directory from a GitHub repo.
Stars: ✭ 180 (-12.62%)
Mutual labels:  downloader
Downloader
Powerful and flexible Android file downloader
Stars: ✭ 193 (-6.31%)
Mutual labels:  downloader
Teemo
C++ File Download Library.
Stars: ✭ 177 (-14.08%)
Mutual labels:  downloader
Saldl
A lightweight well-featured CLI downloader optimized for speed and early preview.
Stars: ✭ 203 (-1.46%)
Mutual labels:  downloader
Invoker
Penetration testing utility, and antivirus assessment tool.
Stars: ✭ 178 (-13.59%)
Mutual labels:  downloader
Downloader Cli
A simple downloader written in Python with an awesome customizable progressbar.
Stars: ✭ 186 (-9.71%)
Mutual labels:  downloader
Xdm
Powerfull download accelerator and video downloader
Stars: ✭ 3,226 (+1466.02%)
Mutual labels:  downloader
Arch Rtorrentvpn
Docker build script for Arch Linux base with ruTorrent, rTorrent, autodl-irssi, Privoxy and OpenVPN
Stars: ✭ 185 (-10.19%)
Mutual labels:  downloader

KJBannerView

功能介绍

KJBannerView 是一款轮播Banner,支持动态图和网图混播

  1. 缩放无限自动循环滚动 √
  2. 支持四种方向滚动,从左往右、从右往左、从上往下、从下往上 √
  3. 自定义继承,定制不同样式,详情使用请见Demo √
  4. 支持网络动态图和网络图片和本地图片混合轮播 √
  5. 支持在Storyboard和Xib中创建并配置其属性 √
  6. 提供多种分页控件PageControl显示 √
  7. 自带缓存加载,内部封装网图下载缓存工具 √
  8. 清理指定时间段以前的图片资源数据 √

使用方法

pod 'KJBannerView' # 轮播图 

API & Property

IB_DESIGNABLE
@interface KJBannerView : UIView
/// 代理方法
@property (nonatomic,weak) id<KJBannerViewDelegate> delegate;
@property (nonatomic,weak) id<KJBannerViewDataSource> dataSource;
/// 暂停计时器滚动处理,备注:在viewDidDisappear当中实现
- (void)kj_pauseTimer;
/// 继续计时器滚动,备注:在viewDidAppear当中实现
- (void)kj_repauseTimer;
/// 滚动到指定位置,备注:需要在设置数据源之后调用
- (void)kj_makeScrollToIndex:(NSInteger)index;
/// 使用Masonry自动布局,请在设置布局之后调用该方法
- (void)kj_useMasonry;

//************************ 数据源API ************************
/// 数据源
@property (nonatomic,strong) NSArray<NSString*>*imageDatas;
/// 自动滚动间隔时间,默认2s
@property (nonatomic,assign) IBInspectable CGFloat autoTime;
/// 是否无线循环,默认yes
@property (nonatomic,assign) IBInspectable BOOL infiniteLoop;
/// 是否自动滑动,默认yes
@property (nonatomic,assign) IBInspectable BOOL autoScroll;
/// 是否缩放,默认不缩放
@property (nonatomic,assign) IBInspectable BOOL isZoom;
/// cell宽度,左右宽度
@property (nonatomic,assign) IBInspectable CGFloat itemWidth;
/// cell间距,默认为0
@property (nonatomic,assign) IBInspectable CGFloat itemSpace;
/// 是否显示分页控件,默认yes
@property (nonatomic,assign) IBInspectable BOOL showPageControl;
/// 滚动方向,默认从右到左
@property (nonatomic,assign) KJBannerViewRollDirectionType rollType;
/// 分页控制器
@property (nonatomic,strong,readonly) KJPageView *pageControl;

//************************ 废弃属性方法 *****************************/
/// 支持自定义Cell,自定义Cell需继承自 KJBannerViewCell
@property (nonatomic,strong) Class itemClass DEPRECATED_MSG_ATTRIBUTE("Please use dataSource [kj_BannerView:BannerViewCell:ImageDatas:Index:]");

@end

//******************** 自带KJBannerViewCell可设置属性 ********************
@interface KJBannerView (KJBannerViewCell)
/// imagView圆角,默认为0px
@property (nonatomic,assign) IBInspectable CGFloat bannerRadius;
/// cell的占位图,用于网络未加载到图片时
@property (nonatomic,strong) IBInspectable UIImage *placeholderImage;
/// 轮播图片的ContentMode,默认为 UIViewContentModeScaleToFill
@property (nonatomic,assign) UIViewContentMode bannerContentMode;
/// 图片的样式,默认 KJBannerViewImageTypeNetIamge 网络图片
@property (nonatomic,assign) KJBannerViewImageType imageType;
/// 是否裁剪,默认NO
@property (nonatomic,assign) BOOL bannerScale;
/// 是否采用动态图缓存,默认NO
@property (nonatomic,assign) BOOL openGIFCache;

@end

@interface KJBannerView (KJBannerBlock)
/// 点击回调
@property (nonatomic,readwrite,copy) void(^kSelectBlock)(KJBannerView *banner,NSInteger idx);
/// 滚动回调
@property (nonatomic,readwrite,copy) void(^kScrollBlock)(KJBannerView *banner,NSInteger idx);

@end

KJBannerView类介绍

Class 功能区
KJBannerView 轮播图主控件
KJPageView 自定义分页控件
KJBannerViewFlowLayout Cell缩放管理
KJBannerViewCell 基类,自定义需继承该Cell
KJBannerViewType 枚举文件夹
KJBannerViewProtocol 委托协议相关
NSTimer+KJSolve 计时器分类
UIImage+KJBannerGIF 动态图分类
KJBannerViewCacheManager 缓存工具
KJBannerViewDownloader 网络请求工具
KJBannerViewLoadManager 网图下载工具
KJBannerWebImageHandle 网图和动态图下载显示协议
UIView+KJWebImage 显示网络图片(目前支持设置UIImageView,UIButton,UIView三种)

支持Xib快捷设置属性

Xib

效果图

轮播图

下载测试效果图,图片采用信号量方式获取

IMG_0145.PNG

打赏作者

  • 如果你觉得有帮助,还请为我 <iframe style="margin-left: 2px; margin-bottom:-5px;" frameborder="0" scrolling="0" width="100px" height="20px" src="https://ghbtns.com/github-btn.html?user=yangKJ&repo=KJBannerViewDemo&type=star&count=true" ></iframe>
  • 如果在使用过程中遇到Bug,希望你能Issues,我会及时修复
  • 大家有什么需要添加的功能,也可以给我留言,有空我将补充完善
  • 谢谢大家的支持 - -!

联系方式 ** Github地址 | 简书地址 | 博客地址 | 掘金地址

谢谢老板

救救孩子吧,谢谢各位老板~~~~

更新日志

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].