Today I have a VC (say called pickVC) that allows the user to pick from a list, i present it modally. I have implemented it like UIImagePickerController, it has a delegate protocol that has didPickItem... didCancelSelection... etc. This works well today.
I create an instance of pickVC, set delegate as the presentingVC, present it, on didSelectRowAt... I fire the delegate method and dismiss it.
I think this is a good way to do it.
I know what to change the architecture to be a UISplitViewController, from reading around, I should use a segue from my MasterVC to my DetailVC. Using a show detail segue, a brand new instance of the detailVC is created with each segue. In prepareForSegue, what is the best way to transfer the data? have a public method on the detailVC and call it from the masterVC to set it up? Use my delegate protocol still?
Thanks,
Daniel Breslan
I create an instance of pickVC, set delegate as the presentingVC, present it, on didSelectRowAt... I fire the delegate method and dismiss it.
I think this is a good way to do it.
I know what to change the architecture to be a UISplitViewController, from reading around, I should use a segue from my MasterVC to my DetailVC. Using a show detail segue, a brand new instance of the detailVC is created with each segue. In prepareForSegue, what is the best way to transfer the data? have a public method on the detailVC and call it from the masterVC to set it up? Use my delegate protocol still?
Thanks,
Daniel Breslan