iOS devices can show title of currently played media on the lock screen (after double click on the home button). I cannot find any Titanium API allowing to control that. Do I miss something or Titanium simply lacks this functionality?
Ok, so it looks like you need to use the MPNowPlayingInfoCenter to interact with that Now Playing media item, which will then in turn display it on the lockscreen. This is not available via a Titanium api, but it looks like you might be able to easily enough create a native module to do it.
Looks like the basic idea is:
NSArray *keys = [NSArray arrayWithObjects:MPMediaItemPropertyAlbumTitle, MPMediaItemPropertyArtist, ..., nil]; NSArray *values = [NSArray arrayWithObjects:@"Album", @"Artist", ..., nil]; NSDictionary *mediaInfo = [NSDictionary dictionaryWithObjects:values forKeys:keys]; [[MPNowPlayingInfoCenter defaultCenter] setNowPlayingInfo:mediaInfo];See the class ref here: http://developer.apple.com/library/ios/#documentation/mediaplayer/reference/MPNowPlayingInfoCenter_Class/Reference/Reference.html
Think you can help? Login to answer this question!