I have an audio recording app. How do I show that the app is recording while the lock screen is on, the way the voice memo app that comes with the iPhone does. Tried playing with MPNowPlayingInfoCenter but haven't gotten anything to work. Any ideas?
Here is what I tried to implement in the IBAction that starts the recording
Class playingInfoCenter = NSClassFromString(@"MPNowPlayingInfoCenter");
if (playingInfoCenter) {
NSMutableDictionary *songInfo = [[NSMutableDictionary alloc] init];
MPMediaItemArtwork *albumArt = [[MPMediaItemArtwork alloc] initWithImage: [UIImage imageNamed:@"record.png"]];
[songInfo setObject:@"Recording" forKey:MPMediaItemPropertyTitle];
[songInfo setObject:albumArt forKey:MPMediaItemPropertyArtwork];
[[MPNowPlayingInfoCenter defaultCenter] setNowPlayingInfo:songInfo];
}