我希望能够从锁定屏幕向前和向后搜索。代码非常简单:
MPRemoteCommandCenter *commandCenter = [MPRemoteCommandCenter sharedCommandCenter];
[commandCenter.seekForwardCommand addTargetWithHandler:^MPRemoteCommandHandlerStatus(MPRemoteCommandEvent *event) {
/// seek forward
return MPRemoteCommandHandlerStatusSuccess;
}];
[commandCenter.seekBackwardCommand addTargetWithHandler:^MPRemoteCommandHandlerStatus(MPRemoteCommandEvent *event) {
/// seek backward
return MPRemoteCommandHandlerStatusSuccess;
}];
但是在锁定屏幕上,播放进度视图不可搜索。
Here是一个类似的问题,但我需要使用MPRemoteCommandCenter
(禁用某些默认控件)。可能有人可以帮助我们两个人)