X-Git-Url: http://git.ithinksw.org/MenuTunes.git/blobdiff_plain/d0b370f6a5079f84d3026ee0fa804a3707de61d2..36c3c74d44819ba8132041dc3b4ee793c2109a69:/MainController.m diff --git a/MainController.m b/MainController.m index 523936c..518d86f 100755 --- a/MainController.m +++ b/MainController.m @@ -39,6 +39,7 @@ static MainController *sharedController; statusWindowController = [StatusWindowController sharedController]; menuController = [[MenuController alloc] init]; df = [[NSUserDefaults standardUserDefaults] retain]; + timerUpdating = NO; } return self; } @@ -202,15 +203,19 @@ static MainController *sharedController; - (void)timerUpdate { - if ( [self songChanged] ) { + if ( [self songChanged] && (timerUpdating != YES) ) { ITDebugLog(@"The song changed."); - [self setLatestSongIdentifier:[currentRemote playerStateUniqueIdentifier]]; + timerUpdating = YES; latestPlaylistClass = [currentRemote currentPlaylistClass]; [menuController rebuildSubmenus]; if ( [df boolForKey:@"showSongInfoOnChange"] ) { [self performSelector:@selector(showCurrentTrackInfo) withObject:nil afterDelay:0.0]; } + + [self setLatestSongIdentifier:[currentRemote playerStateUniqueIdentifier]]; + + timerUpdating = NO; } }