how to show seek track duration on control center

前端 未结 4 1845
无人及你
无人及你 2020-12-24 09:07

How do i pass the song info such as song name and track duration to control center. Player plays music fine and the play and pause control works fine though.

Playin

4条回答
  •  难免孤独
    2020-12-24 09:47

    I happen to be working on the same thing today and don't know the answer, but in my app the Control Center does show the app name. I want to be able to show the title of the thing I'm playing. I even have a picture I'd like to show, like an album cover. I don't think I'm doing anything different than you, I didn't code anything to send it the app name, for example.

    Wait a second... I see there's something called MPNowPlayingInfoCenter that we should look into..

提交回复
热议问题