From 23295fe8df8568122e762b36114db8f3e4ef24a2 Mon Sep 17 00:00:00 2001 From: dec05eba Date: Sat, 14 Jun 2025 22:55:16 +0200 Subject: Matrix: authenticated media requests with access token --- plugins/Matrix.hpp | 5 +++-- plugins/Page.hpp | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) (limited to 'plugins') diff --git a/plugins/Matrix.hpp b/plugins/Matrix.hpp index 23b0a8a..9841510 100644 --- a/plugins/Matrix.hpp +++ b/plugins/Matrix.hpp @@ -548,8 +548,9 @@ namespace QuickMedia { class MatrixVideoPage : public VideoPage { public: MatrixVideoPage(Program *program, std::string filename) : VideoPage(program, ""), filename(std::move(filename)) {} - const char* get_title() const override { return ""; } - std::string get_filename() override { return filename; } + const char* get_title() const override; + std::string get_filename() override; + std::string get_download_url_for_clipboard(int max_height) override; private: std::string filename; }; diff --git a/plugins/Page.hpp b/plugins/Page.hpp index 044759a..9e844b3 100644 --- a/plugins/Page.hpp +++ b/plugins/Page.hpp @@ -165,6 +165,7 @@ namespace QuickMedia { virtual void set_url(std::string new_url) { url = std::move(new_url); } std::string get_url() { return url; } virtual std::string get_download_url(int max_height) { (void)max_height; return url; } + virtual std::string get_download_url_for_clipboard(int max_height) { return get_download_url(max_height); } // Returns empty string for no timestamp or if the video doesn't support timestamps. // Timestamp is in seconds. virtual std::string get_url_timestamp() { return ""; } -- cgit v1.2.3-70-g09d2