1
#ifndef NEWSBEUTER_CONTROLLER__H
2
#define NEWSBEUTER_CONTROLLER__H
8
#include <configcontainer.h>
10
namespace newsbeuter {
18
void set_view(view * vv);
19
void run(int argc = 0, char * argv[] = NULL);
20
bool open_feed(unsigned int pos, bool auto_open);
21
bool open_item(rss_feed& feed, std::string guid);
22
void reload(unsigned int pos, unsigned int max = 0);
24
void start_reload_all_thread();
25
rss_feed& get_feed(unsigned int pos);
26
rss_feed get_feed_by_url(const std::string& feedurl);
27
std::vector<rss_item> search_for_items(const std::string& query, const std::string& feedurl);
28
inline unsigned int get_feedcount() { return feeds.size(); }
29
inline void unlock_reload_mutex() { reload_mutex->unlock(); }
30
void update_feedlist();
31
void mark_all_read(unsigned int pos);
33
inline bool get_refresh_on_start() { return refresh_on_start; }
34
bool is_valid_podcast_type(const std::string& mimetype);
35
void enqueue_url(const std::string& url);
38
void usage(char * argv0);
39
void import_opml(const char * filename);
41
void rec_find_rss_outlines(nxml_data_t * node, std::string tag);
46
std::vector<rss_feed> feeds;
47
std::string config_dir;
49
std::string cache_file;
50
std::string config_file;
51
std::string queue_file;
52
bool refresh_on_start;
53
configcontainer * cfg;