- Extended right-click "Play as audio" to support playlists.

Esse commit está contido em:
trizen
2020-10-31 18:16:03 +02:00
commit 565dcfd83c
+7 -3
Ver Arquivo
@@ -1346,9 +1346,13 @@ sub menu_popup {
my $item = 'Gtk3::ImageMenuItem'->new("Play as audio");
$item->signal_connect(
activate => sub {
my ($video_id, $iter) = get_selected_entry_code();
if (defined($video_id) and $liststore->get($iter, 7) eq 'video') {
execute_cli_pipe_viewer("--id=$video_id --no-video");
my ($id, $iter) = get_selected_entry_code();
my $type = $liststore->get($iter, 7);
if (defined($id) and $type eq 'video') {
execute_cli_pipe_viewer("--id=$id --no-video");
}
elsif (defined($id) and $type eq 'playlist') {
execute_cli_pipe_viewer("--pp=$id --no-video");
}
}
);