亚洲国产日韩欧美一区二区三区,精品亚洲国产成人av在线,国产99视频精品免视看7,99国产精品久久久久久久成人热,欧美日韩亚洲国产综合乱

ios - How to use AFN to pop up the loading box after 3 seconds of network request
大家講道理
大家講道理 2017-06-24 09:44:24
0
1
1037

The product has a requirement that the loading animation pops up after network request 3, but I don’t want to use NSTimer. Is there any easy way

大家講道理
大家講道理

光陰似箭催人老,日月如移越少年。

reply all(1)
迷茫

Objective-C:

dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(3.0 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
    // show loading
});

Swift 3: (Note: self cannot be omitted in block)

DispatchQueue.main.asyncAfter(deadline: DispatchTime.now() + 3) { 
    // show loading
}
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template