Latest 1.0.0
Homepage https://github.com/VolleyZ/ETAdCycleView
License MIT
Platforms ios 8.0
Dependencies Kingfisher
Authors

An auto cycle or loop UIScrollview for horizonal advertisement or banner!一个自动无限循环轮播广告图

Usage


Installation

ETAdCycleView is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod "ETAdCycleView"

Run Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Quick Start

  • In your podfile, just add pod 'ETAdCycleView, then pod update.
  • Write api code to run a networking call:

  • Use frame create
    
    adCycleScroll = ETAdCycleView(frame: CGRect(x: 0, y: 30, width: view.size_width, height: 100))
    view.addSubview(adCycleScroll)

let adImages = ["https://raw.githubusercontent.com/onevcat/Kingfisher/master/images/logo.png"
,
"http://tb1.bdstatic.com/tb/cms/frs/bg/default_head20141014.jpg",
"https://www.baidu.com/img/bd_logo1.png",
""]
adCycleScroll.et_setCycleImagesWithURLs(adImages, placeHolder: UIImage(named: "u86"))


* Use xib or storyboard create

let adCycleImages = ["https://raw.githubusercontent.com/onevcat/Kingfisher/master/images/logo.png"
,
"http://tb1.bdstatic.com/tb/cms/frs/bg/default_head20141014.jpg",
"https://www.baidu.com/img/bd_logo1.png",
""]
ibCycleView.et_setCycleImagesWithURLs(adCycleImages, placeHolder: UIImage(named: "u86"))


* Click image delegate

adCycleScroll.delegate = self

* Delegate

func et_cycleView(didClickPage pageView: UIImageView, atIndex index: Int) {
print("(index)")
}


## License

ETAdCycleView is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "ETAdCycleView",
    "version": "1.0.0",
    "summary": "ETAdCycleView is an auto cycle or loop UIScrollview for horizonal advertisement or banner.",
    "homepage": "https://github.com/VolleyZ/ETAdCycleView",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "VolleyZ": "[email protected]"
    },
    "source": {
        "git": "https://github.com/VolleyZ/ETAdCycleView.git",
        "tag": "1.0.0"
    },
    "source_files": "ETAdCycleView/Class/**/*.{swift}",
    "dependencies": {
        "Kingfisher": [
            "~> 2.1"
        ]
    },
    "platforms": {
        "ios": "8.0"
    }
}

Pin It on Pinterest

Share This