Added remote control event handling to AppDelegate so that example app will show play icon in status bar
This commit is contained in:
parent
d5e531c602
commit
b8528e30c5
|
|
@ -37,6 +37,9 @@
|
|||
|
||||
audioPlayerView.delegate = self;
|
||||
audioPlayerView.audioPlayer = audioPlayer;
|
||||
|
||||
[[UIApplication sharedApplication] beginReceivingRemoteControlEvents];
|
||||
[self becomeFirstResponder];
|
||||
|
||||
[self.window addSubview:audioPlayerView];
|
||||
|
||||
|
|
@ -45,6 +48,11 @@
|
|||
return YES;
|
||||
}
|
||||
|
||||
-(BOOL) canBecomeFirstResponder
|
||||
{
|
||||
return YES;
|
||||
}
|
||||
|
||||
-(void) audioPlayerViewPlayFromHTTPSelected:(AudioPlayerView*)audioPlayerView
|
||||
{
|
||||
NSURL* url = [NSURL URLWithString:@"http://fs.bloom.fm/oss/audiosamples/sample.mp3"];
|
||||
|
|
|
|||
Loading…
Reference in New Issue