animationRepeatCount无法在swift

时间:2015-11-19 15:10:35

标签: ios swift

    var images = [UIImage]()
    for i in 1...perc.integerValue
    {
        var temp : String = ""
        let a :NSNumber = i
        temp="Percentages"+a.stringValue+".png"
        images.append(UIImage(named: temp)!)
    }
    imgView.animationImages = images
    imgView.animationRepeatCount = 1
    imgView.animationDuration = 2
    imgView.startAnimating()

方法animationRepeatCount无效。我跑步时不会显示图像。

0 个答案:

没有答案