It is standard practice to use a parent delegate in a child view controller when performing segues, but I recently learned about the Law of Demeter from NSHipster and thought it would be ideal for the parent to know that its viewWillAppear was the result of returning from the child view controller. The child wouldn't have to know anything about or need to tell the parent anything.
Is there an elegant way to handle this?
Aucun commentaire:
Enregistrer un commentaire