Clean up DanbooruService

Remove multi_get for now (broken in kio_http)
Add a default constructor (needed for QML)
Explicitly delete posts
This commit is contained in:
Luca Beltrame 2015-02-05 23:47:29 +01:00
commit f8b59e78b5
2 changed files with 45 additions and 4 deletions

View file

@ -95,6 +95,7 @@ private:
QString m_password;
QSet<QString> m_blacklist;
DanbooruPost::Ratings m_maxRating;
QHash<int, DanbooruPost*> m_posts;
unsigned int m_postsToFetch; // To tell when to quit
@ -102,6 +103,9 @@ private:
public:
DanbooruService(QObject *parent = 0);
/**
* @brief Construct a default instance of the service.
*
@ -130,8 +134,8 @@ public:
* @param limit The number of posts to fetch (maximum 100)
*
**/
void getPostList(int page = 1, QStringList tags = QStringList(),
int limit = 100);
Q_INVOKABLE void getPostList(int page = 1, QStringList tags = QStringList(),
int limit = 100);
/**
* @brief Get a list of pools from the board.