Skip to content

Instantly share code, notes, and snippets.

@takuma104
Created June 23, 2009 05:36
Show Gist options
  • Save takuma104/134377 to your computer and use it in GitHub Desktop.
Save takuma104/134377 to your computer and use it in GitHub Desktop.
MPMusicPlayerController *mpc = [MPMusicPlayerController iPodMusicPlayer];
MPMediaItem *item = [mpc nowPlayingItem];
NSString *tw = [NSString stringWithFormat:@"Now Playing: %@ - %@ - %@",
[item valueForProperty:MPMediaItemPropertyTitle],
[item valueForProperty:MPMediaItemPropertyAlbumTitle],
[item valueForProperty:MPMediaItemPropertyArtist]];
NSLog("%@", tw);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment