Pete
Pete

Reputation: 219

UISplitViewController - Triggering action in master view from detail view

I am using a UISplitViewController. On the left is the master view with the cells, on the right the Detail View. The cell titles consist of the titles of the details I show on the right. In the Detail View I want to be able to change a text which is equal to the text in the cells of the Master View and have the cells adapt immediately in the Master View. Said differently - a change in the Detail View should trigger an update in the Master View. How can I do this? I have looked everywhere but don't know how to do this.

Upvotes: 0

Views: 46

Answers (1)

David Hoerl
David Hoerl

Reputation: 41622

UISplitViewController has a viewControllers property, which is an array with one or two view controllers in it (depends on the configuration). If you have set it up to always keep the master and detail controllers around, then grab either the first or second, cast it to the proper subclass, and you can then message it.

Upvotes: 1

Related Questions