Skip to content

Instantly share code, notes, and snippets.

@jsjohnst
Forked from erica/Remote access to AirFlick
Created December 26, 2010 22:53
Show Gist options
  • Save jsjohnst/755703 to your computer and use it in GitHub Desktop.
Save jsjohnst/755703 to your computer and use it in GitHub Desktop.
com.sadun.airflick
RequestType := show-photo | play-media
MediaLocation := url or file path
Rotation = 0 | 1 | 2 | 3 (0 ^, 1 <, 2 v, 3 >)
e.g. Photo
NSDictionary *dict = [NSDictionary dictionaryWithObjectsAndKeys:
@"show-photo", @"RequestType",
@"/Users/ericasadun/Pictures/Spring 2010/EPho 3.JPG", @"MediaLocation",
@"1", @"Rotation",
nil];
[[NSDistributedNotificationCenter defaultCenter]
postNotificationName:@"com.sadun.airflick" object:nil
userInfo:dict deliverImmediately:YES];
e.g. Video
NSDictionary *dict = [NSDictionary dictionaryWithObjectsAndKeys:
@"play-media", @"RequestType",
@"/Volumes/MusicAndData/Core Media/TV/SampleVideo.avi", @"MediaLocation",
nil];
[[NSDistributedNotificationCenter defaultCenter]
postNotificationName:@"com.sadun.airflick" object:nil
userInfo:dict deliverImmediately:YES];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment