diff options
author | Rasmus Steinke <rasi@xssn.at> | 2014-12-16 22:29:29 +0100 |
---|---|---|
committer | Rasmus Steinke <rasi@xssn.at> | 2014-12-16 22:29:29 +0100 |
commit | ff9fb3820a8176d4f239226e34541f4b08a5e2e6 (patch) | |
tree | 74efda923b55ab59f87afc89b01d467fdb5dd332 | |
parent | e18317ee949a8f2b82c8fa81d4c718fe99812a8a (diff) | |
download | perl-app-clerk-ff9fb3820a8176d4f239226e34541f4b08a5e2e6.tar.gz perl-app-clerk-ff9fb3820a8176d4f239226e34541f4b08a5e2e6.tar.xz |
make current Queue highlight playing track
-rwxr-xr-x | clerk | 10 |
1 files changed, 9 insertions, 1 deletions
@@ -481,6 +481,14 @@ resumePlaylist () { } dplayQueue () { + displayRofi () { + if [[ $backend == "rofi" ]]; then + dmenu_t -dmenu -p "Queue > " -l $(calc $(mpc current -f %position%) + 3) + elif [[ $backend == "dmenu" ]]; then + dmenu_t -p "Queue > " + fi + } + while read TRACKDISPLAY do TITLE=$(echo "$TRACKDISPLAY" | awk -F "$seperator" '{ print $3 }') @@ -493,7 +501,7 @@ dplayQueue () { else mpc play $POS; fi - done < <(export seperator=$seperator; echo -e "0 Return to Main Menu\n---\nMode: Play\n---\n$(mpc playlist --format "%position%$seperator%artist%$seperator%title%")" | dmenu_t -p "Queue > ") + done < <(export seperator=$seperator; echo -e "0 Return to Main Menu\n---\nMode: Play\n---\n$(mpc playlist --format "%position%$seperator%artist%$seperator%title%")" | displayRofi) exit } |