活动指示器视图在许多应用程序中都很有用。
关于如何在 iPhone 上添加、激活和关闭活动指示器视图有什么想法吗?
这里欢迎所有的方法。
Create:
spinner = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleWhiteLarge];
[spinner setCenter:CGPointMake(kScreenWidth/2.0, kScreenHeight/2.0)]; // I do this because I'm in landscape mode
[self.view addSubview:spinner]; // spinner is not visible until started
Start:
[spinner startAnimating];
Stop:
[spinner stopAnimating];
最终完成后,将微调器从视图中移除并释放。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)