blob: 6f970822a91ba580d2af09f325176ccb96334865 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
#include "../../plugins/ImageBoard.hpp"
namespace QuickMedia {
BodyItems ImageBoardThreadPage::get_related_media(const std::string &url, std::string&) {
BodyItems body_items;
auto it = std::find(cached_media_urls.begin(), cached_media_urls.end(), url);
if(it == cached_media_urls.end())
return body_items;
++it;
for(; it != cached_media_urls.end(); ++it) {
auto body_item = BodyItem::create("");
body_item->url = *it;
body_items.push_back(std::move(body_item));
}
return body_items;
}
std::unique_ptr<RelatedVideosPage> ImageBoardThreadPage::create_related_videos_page(Program*, const std::string&, const std::string&) {
return nullptr;
}
PluginResult ImageBoardThreadPage::login(const std::string &token, const std::string &pin, std::string &response_msg) {
(void)token;
(void)pin;
response_msg = "Login is not supported on this image board";
return PluginResult::ERR;
}
const std::string& ImageBoardThreadPage::get_pass_id() {
static std::string empty_str;
return empty_str;
}
}
|