DWQA QuestionsCategory: ProgramHow to implement two views using one button at the same time in IOS?
Night stars asked 8 months ago

As the question shows, how to achieve it?
It’s still impossible.
I’d better experiment. The cost of trial and error is very low.

AlanZhang replied 8 months ago

If you mean aUIButtonAdd to bothUIViewIf notUIViewCan only exist in one parent view, second timeaddSubviewIt will be removed from the original parent view first. It doesn’t need to check any documents. It can be verified in one minute with playground.