Can you have one view be a preview for several different views for the iPhone?

Is it possible to add the same instance of a view at the same time as a subtitle of two different views? I try to do this, but it only appears on the last one, which was added as a subtitle.

+4
source share
1 answer

No, a view can only be in one hierarchy of views at a time. If you add it to another view, it will be automatically deleted from the previous view. In addition, if you add it to the same view in which it was already, it will be automatically deleted and added as the topmost element (however, it is much less efficient than just changing its position directly).

+12
source

Source: https://habr.com/ru/post/1336292/


All Articles