简体   繁体   中英

How to create a small popup in iOS?

I'm looking for the simplest code in order to implement a small popup (NOT a full screen modal popup or alert view). I just need it to display some basic text inside the popup, then exit it when I click away. The popup in the EleMints app is a good example.

像这样

UIPopoverController does this, but it's limited to iPad only. If you need this on iPhone, just implement a custom UIView subclass. Then when you want to show your popover, instantiate the subclass and add it to your view, maybe with some animation.

You can use WEPopOver as that is the one you required. For more info, visit this link

You can also use the following refrence link for UIPopOver controller

1) WEPopOver Library 2) Popup Bubbles

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM