From 94414a2456d5302305e8801200177e9313b76858 Mon Sep 17 00:00:00 2001 From: Florrie Date: Mon, 25 Feb 2019 12:10:32 -0400 Subject: Don't remove current track when clearing queue --- ui.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ui.js b/ui.js index 90fb13a..eb4a0a9 100644 --- a/ui.js +++ b/ui.js @@ -503,7 +503,10 @@ class AppElement extends FocusElement { } clearQueue() { - this.queueGrouplike.items = [] + // Clear the queue so that there aren't any items left in it (except for + // the track that's currently playing). + this.queueGrouplike.items = this.queueGrouplike.items + .filter(item => item === this.playingTrack) this.queueListingElement.buildItems() this.queueListingElement.pathElement.showItem(null) } -- cgit 1.3.0-6-gf8a5