AlertView? Alert? What is it?

大憨熊 提交于 2019-12-24 07:13:49

问题


I've seen some cool looking "windows" / "alerts" /whatever they are called. I wish I knew. Here's some examples of them:

These shouldn't be Apple exclusive, since I've seen 3rd party apps use them! I'd like to know what are these windows?


回答1:


It Custom UIActivityIndicator that you can found in this link

https://github.com/jdg/MBProgressHUD

MBProgressHUD is an iOS drop-in class that displays a translucent HUD with an indicator and/or labels while work is being done in a background thread. The HUD is meant as a replacement for the undocumented, private UIKit UIProgressHUD with some additional features.......
For mor information go to above Link

Thanks :)




回答2:


These is not apple specific controls. You can create them. The pop up shown in first image is very easy to make. You'll have to use 3 controls to make it.

  1. Background UIImageView with the image.
  2. UIActivityIndicatory
  3. UILabel with whatever message you want to display.

You just have to load this UIImageView and Animate the UIActivityIndicatory to get this pop up. I've used these pop up in a lot of apps Apple don't object this.




回答3:


Your first view is a UIProgressHUD. Original Apple HUD is in a private API and it is not recommended to use it. http://cocoadev.com/wiki/UIProgressHUD

However, numerous implementations have appeared that emulate the original HUD. For one, have a look here: https://github.com/y0n3l/LGViewHUD though I am sure Google will give you a dozen similar implementations.



来源:https://stackoverflow.com/questions/14413645/alertview-alert-what-is-it

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!