mirror of
https://github.com/yattee/yattee.git
synced 2026-07-21 06:42:01 +00:00
Add download row context menu for pause, resume and cancel
Download row actions were wired only as swipe actions, and SwipeActionModifier has #if !os(iOS) overloads that return the view unmodified, so macOS had no way to pause, resume or cancel a download. The video context menu could not cover it either, since the .downloads context deliberately hides the built-in cancel item. Give active download rows their own context menu with pause when queued or downloading, resume when paused, retry when failed, and a destructive cancel. Right-click on macOS, long-press on iOS. Completed rows had a related bug: the delete item called an onDelete callback that DownloadsView never passed, so it rendered but did nothing on macOS. Drop the callback and delete via the download manager directly, which is what already made the same menu work in HomeView. Claude-Session: https://claude.ai/code/session_0154KH8RAVAvm6iVanhmoW8o
This commit is contained in:
@@ -1315,11 +1315,6 @@ struct HomeView: View {
|
||||
DownloadRowView(
|
||||
download: download,
|
||||
isActive: false,
|
||||
onDelete: {
|
||||
Task {
|
||||
await downloadManager?.delete(download)
|
||||
}
|
||||
},
|
||||
queueSource: .manual,
|
||||
sourceLabel: String(localized: "queue.source.downloads"),
|
||||
videoList: videoList,
|
||||
|
||||
Reference in New Issue
Block a user