First, I am not sure if I'm asking this within the correct Stack Exchange community, so if this question belongs somewhere else, please let me know. It didn't seem appropriate for Stack Overflow.
I am developing an audiobook app for iOS that uses a navigation controller to navigate between two TableViewControllers. The first view controller holds a list of books to choose from, and the second holds the list of chapters of those books. When a user clicks the play button of a chapter row, it starts to play the audio for that chapter.
At the bottom of each view controller I've created a custom view that holds the components of a standard audio player (play/pause button, track slider, duration, labels for the current track playing):
Each view controller has its own instance of the audio player view; there isn't a shared, global audio player view (I don't think you can even do this in iOS?).
I would like the state of the audio player at the bottom of both controllers to maintain a shared state as a user navigates around the app. For example, a user plays the Chapter 1 row. I need the audio player view at the bottom of each controller to display that the Chapter 1 entry is playing.
How do I achieve this? I'm fairly new to iOS development, but I believe I need to define a delegate protocol for the audio player view and have each view controller implement it? Or is there a better way of implementing my audio player; maybe creating a custom UIToolbar?