小编and*_*tis的帖子

显示微调器并将其移除到同一个块中

在一个可能需要几秒钟的方法中,我有:

UIActivityIndicatorView *spinner = [[UIActivityIndicatorView alloc]initWithFrame:CGRectMake(135,140,50,50)];
spinner.color = [UIColor blueColor];
[spinner startAnimating];
[_mapViewController.view addSubview:spinner];

// lots of code

[spinner removeFromSuperview];
Run Code Online (Sandbox Code Playgroud)

微调器没有显示出来.可能是因为当时屏幕没有得到更新.我该如何解决这个问题?

uiactivityindicatorview ios

7
推荐指数
1
解决办法
2万
查看次数

标签 统计

ios ×1

uiactivityindicatorview ×1