fix(flutter): 清屏时保留进度条

This commit is contained in:
Zhou Weidong committed 2026-10-20 11:35:48 +08:00
1 parent b26ca6cb9f
commit d849834ce6
2 files changed
+26 -12

No files matched your search

+22 -12
View File
@@ -146,7 +146,11 @@ class PlayerPlaybackOverlay extends StatelessWidget {
bottom: 0,
child: Column(
mainAxisSize: MainAxisSize.min,
children: [if (controlsVisible) _bottomInfo(context), _bottomActions()],
children: [
if (controlsVisible) _bottomInfo(context),
_bottomProgress(),
_bottomActions(),
],
),
);
}
@@ -171,22 +175,28 @@ class PlayerPlaybackOverlay extends StatelessWidget {
authorNote: data.authorNote,
textScale: data.textScale,
),
const SizedBox(height: 2),
SeekProgressBar(
key: const Key('player-progress'),
valueListenable: data.controller,
semanticsLabel: data.l10n.seekVideo,
showTimes: true,
compact: true,
inactiveTrackColor: Colors.white24,
onScrubStart: actions.onScrubStart,
onSeek: actions.onSeek,
),
],
),
);
}
Widget _bottomProgress() {
return Padding(
key: const Key('player-progress-container'),
padding: EdgeInsets.fromLTRB(14, controlsVisible ? 2 : 8, 14, 0),
child: SeekProgressBar(
key: const Key('player-progress'),
valueListenable: data.controller,
semanticsLabel: data.l10n.seekVideo,
showTimes: true,
compact: true,
inactiveTrackColor: Colors.white24,
onScrubStart: actions.onScrubStart,
onSeek: actions.onSeek,
),
);
}
Widget _detailRow(String series) {
return Material(
color: Colors.transparent,