mirror of
https://github.com/zarzet/SpotiFLAC-Mobile.git
synced 2026-09-30 13:19:44 +02:00
feat(player): expand artwork when tapping the compact cover
This commit is contained in:
1 parent
c87c139588
commit
443a9a2bdf
3 files changed
+37
-19
No files matched your search
@@ -1,5 +1,6 @@
|
||||
import 'package:audio_service/audio_service.dart';
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:flutter/gestures.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
/// Shares one horizontal gesture between artwork and metadata. Only the
|
||||
@@ -135,6 +136,8 @@ class PlayerTrackSwipeRegion extends StatelessWidget {
|
||||
if (state == null) return child;
|
||||
return GestureDetector(
|
||||
behavior: HitTestBehavior.translucent,
|
||||
// Keep the initial movement when a cover/title tap competes with a swipe.
|
||||
dragStartBehavior: DragStartBehavior.down,
|
||||
onHorizontalDragStart: state._start,
|
||||
onHorizontalDragUpdate: state._update,
|
||||
onHorizontalDragEnd: state._finish,
|
||||
|
||||
Reference in new issue
Block a user