aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/QuickMedia.hpp13
1 files changed, 8 insertions, 5 deletions
diff --git a/include/QuickMedia.hpp b/include/QuickMedia.hpp
index 0641228..0d4b384 100644
--- a/include/QuickMedia.hpp
+++ b/include/QuickMedia.hpp
@@ -26,6 +26,7 @@ namespace QuickMedia {
class ImageBoardThreadPage;
class RoomData;
class MatrixChatPage;
+ class VideoPage;
enum class ImageViewMode {
SINGLE,
@@ -63,10 +64,14 @@ namespace QuickMedia {
void set_go_to_previous_page();
TaskResult run_task_with_loading_screen(std::function<bool()> callback);
+
+ const char* get_plugin_name() const;
+ void manga_get_watch_history(const char *plugin_name, BodyItems &history_items);
+ void youtube_get_watch_history(BodyItems &history_items);
private:
void base_event_handler(sf::Event &event, PageType previous_page, Body *body, SearchBar *search_bar, bool handle_key_press = true, bool handle_searchbar = true);
- void page_loop(std::vector<Tab> &tabs);
- void video_content_page(Page *page, std::string video_url, std::string video_title, bool download_if_streaming_fails);
+ void page_loop(std::vector<Tab> &tabs, int start_tab_index = 0, std::function<void()> after_submit_handler = nullptr);
+ void video_content_page(VideoPage *video_page, std::string video_url, std::string video_title, bool download_if_streaming_fails);
// Returns -1 to go to previous chapter, 0 to stay on same chapter and 1 to go to next chapter
int image_page(MangaImagesPage *images_page, Body *chapters_body);
void image_continuous_page(MangaImagesPage *images_page);
@@ -88,12 +93,10 @@ namespace QuickMedia {
// Returns PageType::EXIT if empty
PageType pop_page_stack();
- void manga_get_watch_history(const char *plugin_name, BodyItems &history_items);
- void youtube_get_watch_history(BodyItems &history_items);
Json::Value load_video_history_json();
Json::Value load_recommended_json();
- void save_recommendations_from_related_videos(const std::string &video_url, const std::string &video_title, const Body *related_media_body);
+ void save_recommendations_from_related_videos(const std::string &video_url, const std::string &video_title, const BodyItems &related_media_body_items);
private:
enum class UpscaleImageAction {
NO,