Latest 0.0.1
Homepage https://github.com/Aster0id/YCXBannerViewDemo
License MIT
Platforms ios 7.0
Dependencies SDWebImage, DDPageControl
Frameworks UIKit

YCXBannerViewDemo

CocoaPods Version
License

很好用的轮播控件, 可以加载本地图片资源, 可以通过URL链接加载网络图片. 同时可以为图片添加描述文字.

效果

Gif

录制视频

YCXBannerView-record

安装

通过CocoaPods


    # Your Podfile
    platform :ios, '7.0'
    pod 'YCXBannerView'

使用


    images = @[
              [YCXBannerPhoto initWithURL:@"https://raw.githubusercontent.com/Aster0id/TestData/master/img1.jpg" andCaption:nil],
              [YCXBannerPhoto initWithURL:@"https://raw.githubusercontent.com/Aster0id/TestData/master/img2.jpg" andCaption:@"好风景"],
              [YCXBannerPhoto initWithURL:@"https://raw.githubusercontent.com/Aster0id/TestData/master/img3.jpg" andCaption:nil],
              [[YCXBannerPhoto alloc] initWithURL:@"https://raw.githubusercontent.com/Aster0id/TestData/master/img4.jpg"]
              ];

    YCXBannerView *banner = [[YCXBannerView alloc] init];
    banner.photosArray = [self randomPhotoArray];
    banner.delegate = images;
    banner.frame = CGRectMake(0, 0, self.view.frame.size.width, self.view.frame.size.width/2);
    [self.view addSubview:banner];

    [banner reloadData];

TODO

  • BannerView可以设置更多的属性
  • 添加图片加载中的处理
  • 添加图片加载失败的处理

作者

Aster0id, [email protected]

License

MIT License

Latest podspec

{
    "name": "YCXBannerView",
    "version": "0.0.1",
    "summary": "u5f88u597du7528u7684u8f6eu64adu63a7u4ef6, u53efu4ee5u52a0u8f7du672cu5730u56feu7247u8d44u6e90, u53efu4ee5u901au8fc7URLu94feu63a5u52a0u8f7du7f51u7edcu56feu7247. u540cu65f6u53efu4ee5u4e3au56feu7247u6dfbu52a0u63cfu8ff0u6587u5b57.",
    "homepage": "https://github.com/Aster0id/YCXBannerViewDemo",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": "Aster0id",
    "social_media_url": "http://weibo.com/aster0id",
    "platforms": {
        "ios": "7.0"
    },
    "source": {
        "git": "https://github.com/Aster0id/YCXBannerViewDemo.git",
        "tag": "0.0.1"
    },
    "source_files": "YCXBannerViewDemo/YCXBannerView/*.{h,m}",
    "frameworks": "UIKit",
    "dependencies": {
        "SDWebImage": [],
        "DDPageControl": []
    }
}

Pin It on Pinterest

Share This