X-Git-Url: http://git.ithinksw.org/MenuTunes.git/blobdiff_plain/35486a7ded93b3e89a6b03ec1dbe801f3dfe0edc..f26a38c43040219c9af6d93ffa2ef7b1e6d69ce7:/MenuTunes.m diff --git a/MenuTunes.m b/MenuTunes.m index a1121d7..be4dcbf 100755 --- a/MenuTunes.m +++ b/MenuTunes.m @@ -46,17 +46,17 @@ Things to do: currentRemote = [self loadRemote]; [currentRemote begin]; - [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(iTunesTerminated:) name:@"ITMTRemoteAppDidTerminateNotification" object:nil]; - [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(iTunesLaunched:) name:@"ITMTRemoteAppDidLaunchNotification" object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(remotePlayerTerminated:) name:@"ITMTRemoteAppDidTerminateNotification" object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(remotePlayerLaunched:) name:@"ITMTRemoteAppDidLaunchNotification" object:nil]; [self registerDefaultsIfNeeded]; menu = [[NSMenu alloc] initWithTitle:@""]; if ([currentRemote isAppRunning]) { - [self iTunesLaunched:nil]; + [self remotePlayerLaunched:nil]; } else { - [self iTunesTerminated:nil]; + [self remotePlayerTerminated:nil]; } statusItem = [[ITStatusItem alloc] initWithStatusBar:[NSStatusBar systemStatusBar] @@ -67,6 +67,7 @@ Things to do: [statusItem setMenu:menu]; // Below line of code is for creating builds for Beta Testers // [statusItem setToolTip:@[NSString stringWithFormat:@"This Nontransferable Beta (Built on %s) of iThink Software's MenuTunes is Registered to: Beta Tester (betatester@somedomain.com).",__DATE__]]; + [statusWindow orderFront:self]; //DEBUG } - (ITMTRemote *)loadRemote @@ -93,14 +94,14 @@ Things to do: } } -// if ( [remoteArray count] > 0 ) { +// if ( [remoteArray count] > 0 ) { // UNCOMMENT WHEN WE HAVE > 1 PLUGIN // if ( [remoteArray count] > 1 ) { // [remoteArray sortUsingSelector:@selector(sortAlpha:)]; // } // [self loadModuleAccessUI]; //Comment out this line to disable remote visibility // } } - NSLog(@"%@", [remoteArray objectAtIndex:0]); +// NSLog(@"%@", [remoteArray objectAtIndex:0]); //DEBUG return [remoteArray objectAtIndex:0]; } @@ -637,7 +638,7 @@ Things to do: } } -- (void)iTunesLaunched:(NSNotification *)note +- (void)remotePlayerLaunched:(NSNotification *)note { isAppRunning = YES; @@ -649,7 +650,7 @@ Things to do: [statusItem setMenu:menu]; //Set the menu back to the main one } -- (void)iTunesTerminated:(NSNotification *)note +- (void)remotePlayerTerminated:(NSNotification *)note { isAppRunning = NO;