plugin.video.elementum icon indicating copy to clipboard operation
plugin.video.elementum copied to clipboard

[Bug] Using the "Download" from contextmenu show "Playback failed" dialog

Open burekas7 opened this issue 6 months ago • 4 comments

@elgatito @antonsoroko

Using the "Download" option from Elementum context menu options start downloading in the background but also shows the "Playback failed" dialog which shouldn't be shown on this option.

Kodi log debug: https://paste.ubuntu.com/p/9yj9zTRQcZ/plain

  • By the way, when I choose "Delete torrents and files" from context menu in the Torrents list, does it should show a dialog to confirm? Because it doesn't.

Elementum 0.1.98 Elementum Context menu: 0.0.13

burekas7 avatar Dec 24 '23 19:12 burekas7

but also shows the "Playback failed" dialog

this is true.

which shouldn't be shown on this option.

but i am not sure that it can be easily fixed without rewriting a lot of code. for "download" we just re-use "play" code, but then we simply close the "player" immediately. see https://github.com/elgatito/elementum/blob/6aea37dab272b523d6ec42dd75ef123031e388d6/api/play.go#L119

antonsoroko avatar Dec 26 '23 12:12 antonsoroko

By the way, when I choose "Delete torrents and files" from context menu in the Torrents list, does it should show a dialog to confirm? Because it doesn't.

it could, but there is no such code. but i agree - it sounds like a good idea to confirm before delete real files.

antonsoroko avatar Dec 26 '23 12:12 antonsoroko

but also shows the "Playback failed" dialog

this is true.

which shouldn't be shown on this option.

but i am not sure that it can be easily fixed without rewriting a lot of code. for "download" we just re-use "play" code, but then we simply close the "player" immediately. see https://github.com/elgatito/elementum/blob/6aea37dab272b523d6ec42dd75ef123031e388d6/api/play.go#L119

I understand.

@elgatito What do you think?

burekas7 avatar Dec 27 '23 01:12 burekas7

I guess that si because context plugin is calling xbmc.Player().play(url), which expects a playback to start. So for non-playback actions it should use something else.

elgatito avatar Dec 28 '23 16:12 elgatito