From 2fcdff498ad01421e89e35a8971af326d63aab4d Mon Sep 17 00:00:00 2001 From: Spencer Williams Date: Sat, 6 Apr 2024 17:46:10 -0400 Subject: Fix menu selection loss on Sonoma --- mpc-bar.m | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/mpc-bar.m b/mpc-bar.m index f319441..8c699fd 100644 --- a/mpc-bar.m +++ b/mpc-bar.m @@ -8,7 +8,7 @@ #include #include -#define VERSION "0.1" +#define VERSION "0.1.1" #define TITLE_MAX_LENGTH 96 #define SLEEP_INTERVAL 0.2 @@ -117,13 +117,6 @@ static NSString *formatTime(unsigned int t) { struct mpd_song *song = NULL; NSString *errorMsg = nil; - [playPauseItem setEnabled:NO]; - [stopItem setEnabled:NO]; - [nextItem setEnabled:NO]; - [previousItem setEnabled:NO]; - [singleItem setEnabled:NO]; - [updateDatabaseItem setEnabled:YES]; - NSMutableString *output = [NSMutableString new]; status = mpd_run_status(connection); @@ -220,6 +213,7 @@ static NSString *formatTime(unsigned int t) { [singleItem setEnabled:(active && (song_pos < queue_length))]; [clearItem setEnabled:(queue_length > 0)]; + [updateDatabaseItem setEnabled:YES]; cleanup: if (song) -- cgit v1.2.3