From 5d2a7d977f9b0a1604e106f4e2b0c2c9b89c3235 Mon Sep 17 00:00:00 2001 From: dec05eba Date: Thu, 10 Nov 2022 11:53:58 +0100 Subject: Matrix: add settings page with join room and logout button --- plugins/Matrix.hpp | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'plugins') diff --git a/plugins/Matrix.hpp b/plugins/Matrix.hpp index ac3ca3b..152c292 100644 --- a/plugins/Matrix.hpp +++ b/plugins/Matrix.hpp @@ -431,6 +431,25 @@ namespace QuickMedia { const std::string title; }; + class MatrixSettingsPage : public Page { + public: + MatrixSettingsPage(Program *program, Matrix *matrix) : Page(program), matrix(matrix) {} + const char* get_title() const override { return "Settings"; } + PluginResult submit(const SubmitArgs &args, std::vector &result_tabs) override; + private: + Matrix *matrix; + }; + + class MatrixRoomInputPage : public Page { + public: + MatrixRoomInputPage(Program *program, Matrix *matrix) : Page(program), matrix(matrix) {} + const char* get_title() const override { return "Enter the id of a room to join"; } + PluginResult submit(const SubmitArgs &args, std::vector &result_tabs) override; + bool allow_submit_no_selection() const override { return true; } + private: + Matrix *matrix; + }; + // Only play one video. TODO: Play all videos in room, as related videos? class MatrixVideoPage : public VideoPage { public: -- cgit v1.2.3