开发者

app could not be continue with next song in background

I've created a simple music App for iPad using AVAudioPlayer. But the problem is that when I pressed home button it only plays current song in background. The application could not continue with 开发者_如何学编程next song in background.


this works for me

    here musicPlayer is MPMusicPlayerController 

    [self setMusicPlayer: [MPMusicPlayerController applicationMusicPlayer]];

    // By default, an application music player takes on the shuffle and repeat modes

    //      of the built-in iPod app. Here they are both turned off.

    [musicPlayer setShuffleMode: MPMusicShuffleModeOff];

    [musicPlayer setRepeatMode: MPMusicRepeatModeNone];
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜