From f0de15c1939342af2fc702de94e1e6ec81e7ac50 Mon Sep 17 00:00:00 2001 From: dec05eba Date: Sun, 4 Aug 2019 16:04:40 +0200 Subject: Fix crash (x11 multithreading), fix play next video looping instead of next --- README.md | 2 +- src/QuickMedia.cpp | 3 ++- src/main.cpp | 2 ++ 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 39250de..2849bd5 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ # QuickMedia Native clients of websites with fast access to what you want to see # Dependencies -See project.conf \[dependencies] \ No newline at end of file +See project.conf \[dependencies]. youtube-dl also needs to be installed to play videos from youtube. \ No newline at end of file diff --git a/src/QuickMedia.cpp b/src/QuickMedia.cpp index fb29058..c0ae44f 100644 --- a/src/QuickMedia.cpp +++ b/src/QuickMedia.cpp @@ -395,7 +395,8 @@ namespace QuickMedia { video_player->onPlaybackEndedCallback = [this, &related_media, &video_player]() { if(related_media.empty()) return; - video_player->load_file(related_media.front()->url); + video_url = related_media.front()->url; + video_player->load_file(video_url); related_media = current_plugin->get_related_media(video_url); }; } diff --git a/src/main.cpp b/src/main.cpp index 6389370..2dc50ee 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -1,6 +1,8 @@ #include "../include/QuickMedia.hpp" +#include int main() { + XInitThreads(); QuickMedia::Program program; program.run(); return 0; -- cgit v1.2.3