fix: video item menu

Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-01-20 15:47:55 +08:00
parent dfd4bf8077
commit 7544bc2a7f

View File

@@ -28,7 +28,7 @@ class VideoCustomActions {
VideoCustomActions(this.videoItem, this.context, [this.onRemove]) { VideoCustomActions(this.videoItem, this.context, [this.onRemove]) {
actions = [ actions = [
if ((videoItem.bvid as String?)?.isNotEmpty == true) if ((videoItem.bvid as String?)?.isNotEmpty == true) ...[
VideoCustomAction( VideoCustomAction(
videoItem.bvid, videoItem.bvid,
'copy', 'copy',
@@ -42,15 +42,16 @@ class VideoCustomActions {
Utils.copyText(videoItem.bvid); Utils.copyText(videoItem.bvid);
}, },
), ),
VideoCustomAction( VideoCustomAction(
'稍后再看', '稍后再看',
'pause', 'pause',
Icon(MdiIcons.clockTimeEightOutline, size: 16), Icon(MdiIcons.clockTimeEightOutline, size: 16),
() async { () async {
var res = await UserHttp.toViewLater(bvid: videoItem.bvid as String); var res = await UserHttp.toViewLater(bvid: videoItem.bvid);
SmartDialog.showToast(res['msg']); SmartDialog.showToast(res['msg']);
}, },
), ),
],
if (videoItem is! Item) if (videoItem is! Item)
VideoCustomAction( VideoCustomAction(
'访问:${videoItem.owner.name}', '访问:${videoItem.owner.name}',