Latest 1.1.0
Homepage https://github.com/kysonyangs/YSBannerView
License MIT
Platforms ios 8.0
Authors

使用简单、功能丰富、无依赖的 iOS图片、文字轮播器,基于 UICollectionView 实现。

YSBannerView

Installation

pod YSBannerView

使用

  1. 基础使用
    YSBannerView *bannerView = [YSBannerView bannerViewWithFrame:CGRectMake(0, 20, kScrennWidth, 150) imageArray:@[@"http://xxx",@"https://xxx",@"xxx.png"]];
    bannerView.downloadImageBlock = ^(UIImageView *imageView, NSURL *url, UIImage *placeholderImage) {
    // 自定义请求图片方法
    [imageView sd_setImageWithURL:url placeholderImage:placeholderImage];
    };
    [self.view addSubview:bannerView];
  2. 使用自定义Cell, 自行实现以下方法即可
    /// 自定义Cell的样式 返回自定义 Cell 的 Class
    - (Class)bannerViewRegistCustomCellClass:(YSBannerView *)bannerView;
    /// 自定义Cell的样式 返回自定义 Cell 的 Nib
    - (UINib *)bannerViewRegistCustomCellNib:(YSBannerView *)bannerView;
    /// 自定义 Cell 刷新数据或者其他配置
    - (void)bannerView:(YSBannerView *)bannerView setupCell:(UICollectionViewCell *)cell index:(NSInteger)index;

Latest podspec

{
    "name": "YSBannerView",
    "version": "1.1.0",
    "summary": "u4f7fu7528u7b80u5355u3001u529fu80fdu4e30u5bccu3001u65e0u4f9du8d56u7684 iOSu56feu7247u3001u6587u5b57u8f6eu64adu5668",
    "description": "u4f7fu7528u7b80u5355u3001u529fu80fdu4e30u5bccu3001u65e0u4f9du8d56u7684 **iOSu56feu7247u3001u6587u5b57u8f6eu64adu5668**uff0cu57fau4e8e `UICollectionView` u5b9eu73b0u3002",
    "homepage": "https://github.com/kysonyangs/YSBannerView",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "kysonyangs": "[email protected]"
    },
    "source": {
        "git": "https://github.com/kysonyangs/YSBannerView.git",
        "tag": "1.1.0"
    },
    "platforms": {
        "ios": "8.0"
    },
    "source_files": "YSBannerView/Classes/**/*"
}

Pin It on Pinterest

Share This