Recently I ve been wondering about the fact that that an iOS app only has one UIWindow
.
It does not seem to be an issue to create another UIWindow
and place it on screen.
我的问题是模糊的,但我很想:
- What could I potentially achieve with a second
UIWindow
that cannot be done in other ways? - What can go wrong when using multiple
UIWindow
instances? - I have seen that people use a 2nd
UIWindow
to display popover like views on iPhone. Is this a good way of doing it? Why? Why not? - Are there other examples where it is making perfectly sense to have another
UIWindow
?
这并不是说我没有东西。 我从未感到有必要创建另一个<条码>。 例如,但可能允许做令人吃惊的事情,我不知道!
I m hoping that it might help me solve this problem:
I need to add a "cover view" over whatever is currently displayed. It should also work if there are already one or more modal controllers presented. If I add a UIView
to the root controller s view, the modal controllers sit on top, so do the popover controllers.
If I present the cover view modally and there is already a modal controller, only part of the screen is covered.