简体   繁体   中英

How can I reuse a view I built

I am a beginner on mobile dev and i am thinking about the structure of my iPhone app. Its a social app and there is a profile menu like in instagram. Is there a way to create a view and extends it for the personal profile and the profile of other users. I don't want to duplicate the content in the tab view to build the same one in a modal.

Construct the view in a .xib file, which will be turned into a nib file in the running app. Each time you load that nib, you get new copy of the view (and all its subviews, of course).

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