[self timerUpdate];
}
+- (void)makePlaylistWithTerm:(NSString *)term ofType:(int)type
+{
+ ITDebugLog(@"Making playlist with term %@, type %i", term, type);
+ NS_DURING
+ [[self currentRemote] makePlaylistWithTerm:term ofType:type];
+ NS_HANDLER
+ [self networkError:localException];
+ NS_ENDHANDLER
+ ITDebugLog(@"Done making playlist");
+}
+
- (void)showPlayer
{
ITDebugLog(@"Beginning show player.");
if ( [df boolForKey:@"showTime"] ) {
NS_DURING
time = [NSString stringWithFormat:@"%@: %@ / %@",
- @"Time",
+ NSLocalizedString(@"time", @"Time"),
[[self currentRemote] currentSongElapsed],
[[self currentRemote] currentSongLength]];
NS_HANDLER
}
}
- if ( [df boolForKey:@"showPlayCount"] && ![self radioIsPlaying] ) {
+ if ( [df boolForKey:@"showPlayCount"] && ![self radioIsPlaying] && [[self currentRemote] currentSource] == ITMTRemoteLibrarySource ) {
NS_DURING
playCount = [[self currentRemote] currentSongPlayCount];
NS_HANDLER
- (void)setRating:(ITHotKey *)sender
{
- float rating = ([[sender name] characterAtIndex:9] - 48) / 5.0;
- [self selectSongRating:rating];
- [statusWindowController showRatingWindowWithRating:rating];
+ int stars = [[sender name] characterAtIndex:9] - 48;
+ [self selectSongRating:stars * 20];
+ [statusWindowController showRatingWindowWithRating:(float)stars / 5.0];
}
- (void)toggleLoop