Custom iPod Player doesn't update MPMediaItem Values like MPMediaItemPropertyLastPlayedDate
I want to scan the users iPod library with an App. therefore i want to use MPMediaItemPropertyLastPlayedDa开发者_如何学JAVAte for getting the time in seconds (or days, hours) when the song was played the last time.
Problem is, that if i play that song my playing terface within the app (just a view with artwork, title and a play/pause button), the MPMediaItem doesn't get updated in the iPod Library.
is there a way to manually update that just played MPMediaItem after i pressed the play button within my own app.
i guess its supposed to happen somewhere here:
- (void)mediaPicker:(MPMediaPickerController *)mediaPicker didPickMediaItems:(MPMediaItemCollection *)theCollection {
... HOW SHOULD I TELL THE IPOD LIBRARY TO UPDATE e.g. LastPlayedDate or PlayCounter
}
It updates the data, just listen the whole song. After the next song has begun, the last played date and playtime will be set.
It is woring with sharedmusicplayer. I haven't tried with application music player.
精彩评论