My app doesn’t support going back to previous tracks, and I’m wondering if I can tell the lock screen music controls to hide their rewind/previous track button. I use the MPNowPlayingInfoCenter
to communicate that information to the lock screen.
Pretty simple question, can it be done? For instance, to only show Play/Pause, and Skip Forward?
OUTDATED:
I think the short answer is no. The documentation says this -
"You do not have direct control over which information is displayed, or its formatting. You set the values of the now playing info center dictionary according to the information you want to provide to the system. The system, or the connected accessory, handles the information’s display in a consistent manner for all apps."
As of iOS 7.1 there is a way to customize the controls available in the lock screen and command center (and probably many other accessories):
MPRemoteCommandCenter
.Regarding your question you can do the following:
Please see this Stack Overflow answer for more general information about MPRemoteCommandCenter.