From 0f39cf926db49350cd6c6c55649bcf62fe1a2142 Mon Sep 17 00:00:00 2001 From: Chaphasilor Date: Sun, 24 Sep 2023 16:06:57 +0200 Subject: [PATCH] fix dismissing tracks from queue, adjust progress slider color --- lib/components/PlayerScreen/progress_slider.dart | 9 +++++++++ lib/components/PlayerScreen/queue_list_item.dart | 8 +++----- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/lib/components/PlayerScreen/progress_slider.dart b/lib/components/PlayerScreen/progress_slider.dart index 6debf5634..07926eb99 100644 --- a/lib/components/PlayerScreen/progress_slider.dart +++ b/lib/components/PlayerScreen/progress_slider.dart @@ -136,6 +136,15 @@ class _BufferSlider extends StatelessWidget { thumbShape: HiddenThumbComponentShape(), trackShape: BufferTrackShape(), trackHeight: 4.0, + inactiveTrackColor: IconTheme.of(context).color!.withOpacity(0.35), + // thumbColor: Colors.white, + // overlayColor: Colors.white, + activeTrackColor: IconTheme.of(context).color!.withOpacity(0.6), + // disabledThumbColor: Colors.white, + // activeTickMarkColor: Colors.white, + // valueIndicatorColor: Colors.white, + // inactiveTickMarkColor: Colors.white, + // disabledActiveTrackColor: Colors.white, ), child: ExcludeSemantics( child: Slider( diff --git a/lib/components/PlayerScreen/queue_list_item.dart b/lib/components/PlayerScreen/queue_list_item.dart index 84adbce0c..cb32a4a7a 100644 --- a/lib/components/PlayerScreen/queue_list_item.dart +++ b/lib/components/PlayerScreen/queue_list_item.dart @@ -55,12 +55,10 @@ class _QueueListItemState extends State { Widget build(BuildContext context) { return Dismissible( key: Key(widget.item.id), - onDismissed: (direction) { - setState(() { - _queueService.removeAtOffset(widget.indexOffset); - // widget.subqueue.removeAt(widget.listIndex); - }); + onDismissed: (direction) async { Vibrate.feedback(FeedbackType.impact); + await _queueService.removeAtOffset(widget.indexOffset); + setState(() {}); }, child: GestureDetector( onLongPressStart: (details) => showSongMenu(details),