Skip to content

Commit

Permalink
Modified Show Player state format.
Browse files Browse the repository at this point in the history
  • Loading branch information
carlosefonseca committed Mar 23, 2020
1 parent 07550c4 commit 95746d6
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Statusfy/SFYAppDelegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ - (void)setStatusItemTitle

if ([self getPlayerStateVisibility]) {
NSString *playerState = [self determinePlayerStateText];
titleText = [NSString stringWithFormat:@"%@ (%@)", titleText, playerState];
titleText = [NSString stringWithFormat:@"%@ %@", playerState, titleText];
}

self.statusItem.image = nil;
Expand Down Expand Up @@ -114,13 +114,13 @@ - (NSString *)determinePlayerStateText
NSString *playerStateConstant = [[self executeAppleScript:@"get player state"] stringValue];

if ([playerStateConstant isEqualToString:@"kPSP"]) {
playerStateText = NSLocalizedString(@"Playing", nil);
playerStateText = NSLocalizedString(@"\u25B6", nil);
}
else if ([playerStateConstant isEqualToString:@"kPSp"]) {
playerStateText = NSLocalizedString(@"Paused", nil);
playerStateText = NSLocalizedString(@"❙ ❙", nil);
}
else {
playerStateText = NSLocalizedString(@"Stopped", nil);
playerStateText = NSLocalizedString(@"\u25FB\uFE0F", nil);
}

return playerStateText;
Expand Down

0 comments on commit 95746d6

Please sign in to comment.