Add 'Copy URL' to download context menu

See #1078
This commit is contained in:
Florian Bruhin 2021-01-25 18:50:57 +01:00
parent 2d6d9e108e
commit 68b81511e5
2 changed files with 3 additions and 0 deletions

View File

@ -118,6 +118,7 @@ Added
show when `:open` is used without any input.
- New `QUTE_VERSION` variable for userscripts, which can be used to read
qutebrowser's version.
- New "Copy URL" entry in the context menu for downloads.
- New userscripts:
* `kodi` to play videos in Kodi
* `qr` to generate a QR code of the current URL

View File

@ -140,6 +140,8 @@ class DownloadView(QListView):
actions.append(("Remove", item.remove))
else:
actions.append(("Cancel", item.cancel))
actions.append(("Copy URL", functools.partial(
utils.set_clipboard, item.url().toDisplayString())))
if model.can_clear():
actions.append((None, None))
actions.append(("Remove all finished", model.download_clear))