i have a uiview and a uiwebview. at the moment they have no relationship with one another because i'm stuck at figuring out the 'correct' way to set them up. it really makes no difference to me, but i'd like to know which way is best.
on one hand, i could make the uiwebview a subview of my uiview. that would work for my purposes. however, it just seems weird that i'd be setting this up within my custom uiview class - i mean, isn't this the job of a viewcontroller?
on the other hand, i could treat both views as equals and let the view controller switch them out perhaps? but my custom uiview responds to events (such as touchesEnded) and only it knows when it's time is up and it's to be replaced by the uiwebview. the viewcontroller has no knowledge of this and therefore cannot know when to switch between the two.
any insight on the best approach here? thanks!
on one hand, i could make the uiwebview a subview of my uiview. that would work for my purposes. however, it just seems weird that i'd be setting this up within my custom uiview class - i mean, isn't this the job of a viewcontroller?
on the other hand, i could treat both views as equals and let the view controller switch them out perhaps? but my custom uiview responds to events (such as touchesEnded) and only it knows when it's time is up and it's to be replaced by the uiwebview. the viewcontroller has no knowledge of this and therefore cannot know when to switch between the two.
any insight on the best approach here? thanks!